944,079 Members | Top Members by Rank

Ad:
Oct 8th, 2009
0

PLEASE help me with this pseudocode problem!!!!

Expand Post »
I'm totally stuck on this problem for homework::
*** Write pseudocode to represent the logic of a program that allows the user to enter values that represent the radius of a Circle. The Program calculates the Diameter (by multiplying the Radius by 2) and then calculates the Circumference (by multiplying the Diameter by 3.14). The program prints both the Diameter and Circumference.***


This stuff is kinda confusing to me and my class book isn't helping me much. This is what I've come up with, but it looks wrong to me but I don't know which parts are and what I should fix or change::::


Start
input radius
compute diameter as radius times 2
print diameter
circumference = diameter times 3.14
print diameter, circumference
end



Btw, THANK YOU to all who helps me! =)
Similar Threads
Reputation Points: 10
Solved Threads: 0
Newbie Poster
OrangeNaa is offline Offline
2 posts
since Oct 2009
Oct 9th, 2009
1
Re: PLEASE help me with this pseudocode problem!!!!
It looks ok to me. Pseudocode doesn't really have a "standard" format (that I know of) - if an experienced programmer were writing that pseudocode, it would look a bit different - but I think you covered most of the steps, which is the important thing. A program wouldn't just "input radius" though. You need to prompt the user first, asking them to input the radius, then you need to read that value into the radius variable.
Reputation Points: 874
Solved Threads: 352
Posting Maven
BestJewSinceJC is offline Offline
2,758 posts
since Sep 2008
Oct 9th, 2009
1
Re: PLEASE help me with this pseudocode problem!!!!
Oh, another thing - you printed the diameter twice, but your project description asks for you to print it once.
Reputation Points: 874
Solved Threads: 352
Posting Maven
BestJewSinceJC is offline Offline
2,758 posts
since Sep 2008
Oct 15th, 2009
0
Re: PLEASE help me with this pseudocode problem!!!!
Thank you very much for the help!! Not only did you really help me out, but you came back and made sure you gave me the correct evaluation! It's very appreciated=) Take care!!
Reputation Points: 10
Solved Threads: 0
Newbie Poster
OrangeNaa is offline Offline
2 posts
since Oct 2009

This thread is solved

Either the thread starter or a moderator has marked this thread as solved. You can most likely trust the responses and answers given. There is most likely no reason for any further responses to be posted here. If you have a related question, please start a new thread in this forum instead.

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in Computer Science Forum Timeline: Need help with Karnaugh map
Next Thread in Computer Science Forum Timeline: Structured Systems Analysis and Design





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC