练习专区

今天的一小步就是明天的一大步
Problem 1659 while循环...............java
Accepted: 2   Total Submit: 19
Time Limit: 1000ms   Memory Limit: 30720KB
Description

请编写一个JAVA程序,用while循环计算1+1/2!+……+1/n!的值

Input

用赋值语句输入n值

Output

要求输出n=值,然后间隔一个制表符 ,再输出1+1/2!+……+1/n!=值

Sample Input
int n=10;
Sample Output
n=10	1+1/2!+……+1/n!=1.7182818011463847
Hint
提交     返回