文件名称:AssignmentSharp1
- 所属分类:
- JSP源码/Java
- 资源属性:
- [Java] [源码]
- 上传时间:
- 2012-11-26
- 文件大小:
- 180kb
- 下载次数:
- 0次
- 提 供 者:
- A***
- 相关连接:
- 无
- 下载说明:
- 别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容均来自于网络,请自行研究使用
Write a program that takes the x-y coordinates of a point in the Cartesian plan and print a message in a message dialog box telling either an axis in which the point lies or the quadrant in which it is found.
Sample line of output:
(-1.0, -2.5) is in quadrant III.
(0.0, 4.8) is on the y axis.
Task 3
Given: Sin(x) = x – x3 /3! + x5 /5! – x7 /7! + …
Cos(x) = 1 – x2 /2! + x4 /4! – x6 /6! + …
Write a Java program that does the following:
1. Reads a positive value x
2. Write two methods to compute sin(x) and cos(x) using the above formula. The summation in the loop above will stop (loop stops) whenever the value of the term becomes less than 0.0001.
3. Invoke the above methods and print either sin(x) or cos(x) depending on the user choice.
the file including the assigment and the solution
Sample line of output:
(-1.0, -2.5) is in quadrant III.
(0.0, 4.8) is on the y axis.
Task 3
Given: Sin(x) = x – x3 /3! + x5 /5! – x7 /7! + …
Cos(x) = 1 – x2 /2! + x4 /4! – x6 /6! + …
Write a Java program that does the following:
1. Reads a positive value x
2. Write two methods to compute sin(x) and cos(x) using the above formula. The summation in the loop above will stop (loop stops) whenever the value of the term becomes less than 0.0001.
3. Invoke the above methods and print either sin(x) or cos(x) depending on the user choice.
the file including the assigment and the solution
(系统自动生成,下载前可以参看下载内容)
下载文件列表
Assignment#1\Assignment1.doc
............\task3\task3.java
............\.....\task3.JPG
............\....2\calender.class
............\.....\calender.java
............\.....\calender.JPG
............\....1\task1 2.JPG
............\.....\task1 3.JPG
............\.....\task1 4.JPG
............\.....\task1.JPG
............\.....\Task_1.class
............\.....\Task_1.java
............\.....\Thumbs.db
............\task3
............\task2
............\task1
Assignment#1
............\task3\task3.java
............\.....\task3.JPG
............\....2\calender.class
............\.....\calender.java
............\.....\calender.JPG
............\....1\task1 2.JPG
............\.....\task1 3.JPG
............\.....\task1 4.JPG
............\.....\task1.JPG
............\.....\Task_1.class
............\.....\Task_1.java
............\.....\Thumbs.db
............\task3
............\task2
............\task1
Assignment#1