Re: looking to create javascript quiz/questionaire
Available news archives: comp.lang.tcl - comp.lang.python - comp.security.firewalls - sci.crypt - comp.lang.php - comp.lang.javascript
Google
 
Web news.hping.org


comp.lang.javascript archive

Re: looking to create javascript quiz/questionaire

From: <admin@stacksback.com>
Date: Thu Mar 23 2006 - 03:58:02 CET

Just an update, I've decided on the method I'd like to use.

Assuming there are 6 questions in my quiz, some with 2 possible
answers, some with 3 or 4... I assign each answer a 6 digit number.
then, I total them up.

Make sense? For question 1, in which the answer is either A) or B),
the variables would be 100,000 or 200,000... then for question 2, using
a 5 digit number, and so forth.

For example,

200,000 +
010,000 +
003,000 +
000,200 +
000,040 +
000,003 = 213,243, which is now a variable, that contains information
about how each of 6 questions was answered.

It appears I'll have 288 possible combinations, which I'll analyze
myself and offer a 'solution' for.

I'm still unsure about how to code it. How do I assign integer
variables for each of the possible answers, then give the instruction
to total them, then associate a 'solution' with each possible answer?
Any advice about how to get started would be greatly appreciated.

-Chris
Received on Mon May 1 04:21:09 2006