TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
C# Corner
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Calculate The Serious Program Using Java
Senthilvelan Sambamoorthy
Aug 12
2016
Code
593
0
0
facebook
twitter
linkedIn
Reddit
WhatsApp
Email
Bookmark
expand
ssva8.rar
// serious program
import
java.io.*;
import
java.text.*;
import
java.lang.Math;
class
ssva8
{
public
static
void
main(String arg[])
throws
IOException
{
double
i=
1.0
,j=
0.1
;
BufferedReader obj=
new
BufferedReader(
new
InputStreamReader(System.in));
System.out.print(
"\nENTER THE VALUE N>1.0 : "
);
double
n=Double.parseDouble(obj.readLine());
System.out.print(
"\nENTER THE VALUE M>0.1 : "
);
double
m=Double.parseDouble(obj.readLine());
System.out.println(
"\n"
);
NumberFormat nf= NumberFormat.getInstance();
for
(i=
0.0
;i<=n;i=i+
1.0
)
{
for
(j=
0.0
;j<=m;j=j+
0.1
)
{
System.out.print(nf.format(Math.sqrt(i+j))+
" "
);
}
System.out.println(
"\n"
);
}
}
}
Java