First of all, I don't see what you have already written for this problem, it's hard for me to pin point what is not correct.
Can you show you solution and we can go from there.
Thanks and regards
Jia Jiunn Wong
____________
From: Preyas Patel <patelpreyasi@
To: Java_Official@
Sent: Sunday, October 11, 2009 5:27:06 PM
Subject: [Java] Please hep me writing my first java program!!
Q. Write a Java program that reads in the length and width of a rectangular yard and the length and the width of a rectangular house situated in the yard. Your program should compute the time required (In minutes) to cut the grass at the rate of 2.3 square meters a second.
Output Format:
Yard Length: ________
Yard width: _________
Yard Area: ________
House Length: ________
House Width: ________
House Area: _________
Grass Area: __________
Cutting Time: ________
The above is the question of my assignment and I have came up with below algorithm.
1 Input the length of yard
2 Input the width of yard
3 Input the length of house
4 input the width of the house
5 Area of the House ß Length of the house * Width of the house
6 Area of the Yard ß Area of the house – (Length of the yard * Width of the yard)
7 Time Required cutting the grass ß Area of yard/2.3 m. square/sec/60
8 Print Times
I tried really hard to write program but I don't know I am having problem and I can't get it correct. Well this is my first ever java assignment so I found it little hard for me. So if you please can help me writing the program.
Regards, ------------ --
Preyas Patel
B.S. Computer Science
California State University, Northridge
+ 1 619 200 4818
patelpreyasi@ yahoo.co. in
patelpreyas2@ gmail.com
From cricket scores to your friends. Try the Yahoo! India Homepage! http://in.yahoo. com/trynew
[Non-text portions of this message have been removed]
[Non-text portions of this message have been removed]
Java Official Group is created for the following topics: Java 2 Enterprise Edition - J2EE, Java 2 Standard Edition - J2SE, Java 2 Micro Edition - J2ME, XML, XSL, XSD, XPATH, Web Services, Jini, JXTA for all type of Java Geeks.
Whoever posts spam / ads / job related message will be BANNED IMMEDIATELY
Change settings via the Web (Yahoo! ID required)
Change settings via email: Switch delivery to Daily Digest | Switch format to Traditional
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe
No comments:
Post a Comment