Basic Coding

Please use this Board for QBasic related requests ( file research, programming, etc.)

Moderators:Administrator, Global Moderator

Post Reply
Guest
Basic Coding

Post by Guest » Mon May 13, 2002 2:36 pm

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?

Guest

Re: Basic Coding

Post by Guest » Tue May 21, 2002 3:38 am

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.

Post Reply