Assignment #2 - JavaScript

Due Wednesday, June 25th

  1. Your web page will have two frames. It will consist of two rows, a top frame and a bottom frame.

  2. The top frame will consist of a web page that is an interactive practice quiz for the first two weeks material in 810:088. It will have a total of 8 questions.

    See a fourteen question interactive Discrete Structures self-grading practice quiz from fall of 2001, to get the idea.

  3. There will be three true/false questions. Use the checkbox control to represent answering FALSE when it is unchecked and answering TRUE when it is checked. Page 315 of the textbook is where Checkboxes discussion begins.

  4. There will be two multiple choice questions. Use Radio Buttons to implement the 4 or 5 multiple choice answers for each question. Radio buttons discussion begins on page 311 of text.

  5. There will be three fill in the blank questions. They should be one or two word short answer. If the answer to a question was Panthers, it should not matter whether the user typed panthers, PANTHERS, pANTHERS, or Panthers when your JavaScript code grades their quiz.

  6. When the user clicks the Grade Quiz (or Grade Em) button, the results of their quiz will be posted or written to the bottom frame. Just tell the user how many answers they got correct. You do not need to tell them which questions they got right and which ones they got wrong. Obviously, their goal is to get 8 out of 8 correct.

  7. When the quiz is graded, greet the user by their name. Examples:
       Way to go, Bilbo.  You got 7 out of 8 correct.
       Keep trying Cinderella.  You answered 4 out of 8 correctly.
       Do not give up.  You can DO it, Carlos.  You got 2 of 8 okay.

  8. There will be one question with a link for either help or for a diagram or figure of some JavaScript code that gets displayed in a separate browser window. When the user clicks this link they can read more about the topic of the question, or see some JavaScript code or a diagram that the question refers to. They can see that in a separate window, while they have the original question also in view on their screen.

  9. This hints or help or figure/diagram/code window will automatically close when they exit the quiz and go so some other web page (by using the Back button, their bookmarks or typing in a new URL). This involves the onUnload() Event Handler, just as we studied it in class and in examples that are available at the ~jacobson/c088.html web page.

  10. There will be a cookie to get the user or the quiz taker's name when they arrive at this URL. That cookie will store the user's name, so we don't have to ask them again if they leave this we site and come back again later.

  11. Your eight questions should be related to what we have been studying during the first two weeks of class. It will be good review of the class to go through your lecture notes, readings and handouts and develop 15 or 20 questions and then choose the best eight to make a self-grading, interactive practice quiz with.

  12. Study over the class web site, your handouts, lecture notes and the readings as you prepare and do this assignment. All the techniques that you need to use are illustrated in examples from my web site.

Back to 810:088 class page or back to the class summaries page.