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

Username:   Password: 
 RegisterRegister   
 loops and getching at same time
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
poomanchunk




PostPosted: Sun May 09, 2004 7:04 pm   Post subject: loops and getching at same time

Ok I know theres a way to do this (or think anyways), but I have no idea how to. I want to be able to continue the loop, even through a getch
Like this is what I got
code:
for decreasing count : 15 .. 1
    put count
    getch answer
    if answer is = "a" then
    (and it goes on with the selection)
    end if
end for

Now this is like a counter. BTW i'm trying to make jeopardy, and the 15 is the counter. I want it to keep counting, and if someone presses 'a' then it'll stop.
Can someone plz help me on this.
Thx
Sponsor
Sponsor
Sponsor
sponsor
Tony




PostPosted: Sun May 09, 2004 7:08 pm   Post subject: (No subject)

code:

if hasch then
getch answer
end if
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
poomanchunk




PostPosted: Sun May 09, 2004 7:38 pm   Post subject: (No subject)

Hmm.. I haven't learned about hasches yet, I'll have to look into this.
Seems complicated. Anyways thx for the help, I'll see if I can manage to do something.

Edit - Ok I figured it out, wasnt' too hard Smile
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  [ 3 Posts ]
Jump to:   


Style:  
Search: