Monday, July 27, 2009

Creating a quiz for students?

Hi guys, I am thinking of writing a program in C which will help elementary students learn simple arithmetic. I am planning to use a random number generating function to produce two positive one-digit integers. It should then type a question like:


How much is 6 times 7?. the student is then supposed to type the answer. heres the random number generating function. I am just having some problems writing the code:





int


main ( void )


{


/* Declarations */











srand( time( NULL ) ); /* seed random number generator */





/* rest of the code */ (heres where my problem is)














return EXIT_SUCCESS;


}





/* Function : randNum


* Input : k - an integer


* Returns : an integer - the psuedo-random integer generated


int randNum ( int k )


{


double x = RAND_MAX + 1.0;


int y;





y = 1 + rand () * (k / x);


return

Creating a quiz for students?
Well, a fun way to help the kids learn is to incorperate the use of fun electronics such as an iPod. You can make custom trivia packs to use with an iPod game that is like a quiz show. You could them e-mail them the links or something and they could then put them onto their iPod and practice on the Quiz Show Game. Good Luck!


No comments:

Post a Comment