Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 how to make a range?
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
batgirl13




PostPosted: Tue Oct 07, 2008 9:41 am   Post subject: how to make a range?

i need my program to display specific text based on the number entered....for example if i enter a number between 50 and 60, i need it to say satisfactory, 70-100, good, ect.
i cant remember what the code is...does anyeone know?
Sponsor
Sponsor
Sponsor
sponsor
S_Grimm




PostPosted: Tue Oct 07, 2008 10:12 am   Post subject: RE:how to make a range?

if
elsif
else
gitoxa




PostPosted: Tue Oct 07, 2008 3:31 pm   Post subject: RE:how to make a range?

You're wanting to use a decision structure. Check out the Turing Walkthrough the if structures section
S_Grimm




PostPosted: Tue Oct 07, 2008 6:54 pm   Post subject: RE:how to make a range?

in other words if # > #2 and <#3 then
elsif # >#3 and <#4 then
end if
andrew.




PostPosted: Tue Oct 07, 2008 8:30 pm   Post subject: RE:how to make a range?

Press F10 in Turing and look up if statements. You may also want to check out the tutorial here (like gitoxa said).

Turing Walkthrough
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 5 Posts ]
Jump to:   


Style:  
Search: