为这两个问题创建代码 [英] create codes for these two problems

查看:61
本文介绍了为这两个问题创建代码的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

1. 二项式系数

假设您的UCID是"abc123",请创建一个以您的UCID"abc123"命名的新文件夹.
将计算概率的函数文件放在"abc123"中
还要在"abc123"中创建另一个文件夹"private",并将两个计算二项式系数和n的函数文件放入!在私人"中
将包含所有内容的"abc123"压缩为zip或tar文件,即abc123.zip或abc123.tar
注意,不正确的文件夹名称或压缩文件格式将导致零



2.
教科书P.419上的练习8.15

将弧度转换为度,分,秒
角度通常以度,分钟和秒为单位,以360度为圈,以60分钟为度,以分钟为60秒来度量.编写一个程序,该程序从输入磁盘文件中读取以弧度为单位的角度并将其转换为度,分和秒.输出应写入另一个文件.输入文件示例可以是:
#这是一条注释#您的程序应该能够跳过注释行#和空白行#输入的弧度数可以用空格0.0 1.0#或换行符3.141593 6.0
分隔 此样本输入也可以从课程网页下载,并用作您的测试输入文件.向用户询问输入和输出文件名.相应地设计您的输出文件.

1. Binomial Coefficients

Suppose your UCID is "abc123" Create a new folder named by your UCID "abc123"
Put the function file that computes the probability in "abc123"
Also create another folder "private" in "abc123" and put the two functions files that compute binomial coefficient and n! in "private"
Compress "abc123" with everything in it into a zip or tar file, i.e., abc123.zip or abc123.tar
Note, incorrect folder names or compressed file formats will result in a zero



2.
Modified Exercises 8.15 on P.419 of textbook

Converting Radians to Degrees, Minutes, Seconds
Angles are often measured in degrees, minutes, and seconds, with 360 degrees in a circle, 60 minutes in a degree, and 60 seconds in a minute. Write a program that reads angles in radians from an input disk file and converts them into degrees, minutes, and seconds. Output should be written into another file. A sample input file could be:
# this is a comment # your program should be able to skip comment lines # and blank lines # input radian numbers could be seperated by blanks 0.0 1.0 # or by a newline 3.141593 6.0
This sample input can also be downloaded from the course webpage and used as your test input file. Ask the user for the input and output file names. Design your output file accordingly.

推荐答案

这样做.您正在学习Matlab,而不是我们.
So do it. You''re learning Matlab, not us.


至少给我一些钱,我可以做您的作业!尝试自己动手做,然后再提出一些具体问题!
At least give me some money I can do your homework! Try do it by yourself and then go back with specific questions!


在这里它不能像这样工作.抱歉,这里没有快速提问.这听起来像是您的大学项目/作业,您应该付出一些努力.

我们希望您花一些时间来尝试解决您面临的问题,然后再花一些时间在此处发布问题时提出问题.

这是询问者的期望:
1. 先尝试您要做什么!
2.制定看起来像问题/无法解决的问题.

试试看,告诉他们是否遇到问题.
成员将很乐意为您提供帮助.
It does not work like this here. I am sorry but there is no quick question here. This sounds like your college project/assignment, you should put some effort.

We expect you to put some time in trying the issue that you are facing and then some time in formulating the question while posting here.

Here is what is expected by enquirers:
1. TRY first what you want to do!
2. Formulate what was done by you that looks like an issue/not working.

Try them and tell if you face issues.
Members will be more than happy to help like this.


这篇关于为这两个问题创建代码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆