CODE
'This program will allow the user to enter a series of temperatures
'in celsius (C) terminated by the input of -999. Then the temperatures
'will be converted from Celcius to farenheit(F)
'Define Global Variables
global farenheit, celsius, temperatures
'Define an array capable of storing ten celsius temperatures
dim temperatures (10)
temperature(1)
temperature(2)
temperature(3)
temperature(4)
temperature(5)
temperature(6)
temperature(7)
temperature(9)
temperature(10)
'Load the tempertures in celcius
print " please enter temperature in celsuis"; celsius (10)
input temperature
let farenheit= 9*celsius/5+32
print "farenheit temperature:"; farenheit
end
okay I am not really sure of what i am doing i have some real basic codes but believe this needs to have an array of some sort or possibly a pre or post test loop to help display the temperatures as the user inputs them. it may be a do while or if then else clause. I am looking for direction on what it needs as i am needing to input more than one temperature in celcius and then convert and display them in fareinheit like maybe a table. please do not just send me the code to make this work as i do not find that is what will help me learn and understand it. this is a homework assignment and i would like to do it but am asking for some direction or suggestions to how to write the loops or if i need loops. I am also confused about the celcius temperatures terminated by -999. I am not sure what this means. I am thinking it means that the celcius temperature needs to be higher then -999 and if not then it goes back to the beginning of the loop. any direction and suggestion would be a great help. thank you in advance for your time and efforts.
I also have to write a program in Raptor for this same thing and have started that and got stuck so if you have any suggestion on that I would also need them too. I will attach my raptor flowchart that i started and need some suggestiosn regarding that. again please do nto give me the answers as i do not want someone to do this for me i want to learn what to do and apply it. thanks
This post has been edited by lkg4btrlife: 18 Oct, 2009 - 05:24 PM