This week's book giveaway is in the Big Data forum.
We're giving away four copies of Elasticsearch in Action and have Radu Gheorghe & Matthew Lee Hinman on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes Correct output for this program? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Elasticsearch in Action this week in the Big Data forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Correct output for this program?" Watch "Correct output for this program?" New topic
Author

Correct output for this program?

Matt Kidd
Ranch Hand

Joined: Jul 17, 2002
Posts: 266
This is the program:

This is the output I came up with:
1
4
9
16
25
36
49
64
81
100
Total is 385
Am I correct?
[ August 08, 2002: Message edited by: Matt Kidd ]
Chad McGowan
Ranch Hand

Joined: May 10, 2001
Posts: 265
You are correct. You could have found this out by running the program yourself!
Matt Kidd
Ranch Hand

Joined: Jul 17, 2002
Posts: 266
mental note....
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Correct output for this program?