Page 1 of 1

Basic Coding

Posted: Mon May 13, 2002 2:36 pm
by Guest
I have to make a game using QBasic coding for school, and I want to make a quiz but I don't know the code for the following:
1) adding the score of the quiz
2) Checking which thing you picked (A,B,C, or D) and getting the correct score
If anyone knows how to do any of these can you please tell me?

Re: Basic Coding

Posted: Tue May 21, 2002 3:38 am
by Guest
print "Arg says the_____"
print "A) Pirate"
print "B) Random guy"
print "C) Bald man"
input bleh(x)
'x being the number of the question and bleh(x) being the array your storing the user's responces in.

'then to check use an if statement like so
if bleh(1)="A" then correct=correct+1

'correct is an acumulator that adds up how many answers the user has gotten right.
'if i'm not right feel free to e-mail me your thoughts on how stupid i am.