Skip to content

Instantly share code, notes, and snippets.

@theRemix
Last active August 29, 2015 14:02
Show Gist options
  • Select an option

  • Save theRemix/cd080097b97a929d3cce to your computer and use it in GitHub Desktop.

Select an option

Save theRemix/cd080097b97a929d3cce to your computer and use it in GitHub Desktop.

Javascript Project DomQuiz

  1. Set up a new project directory called “DomQuiz”
  2. Initialize a git repo
  3. Set up an html5 file named index.html
  4. Write a paragraph element with an id of “question
  5. Write an input text field with an id of “answer
  6. Add a button with an id of “submit
  7. commit
  8. Add a script tag to execute an external js file named dom_quiz.js
  9. Create the dom_quiz.js file.
  10. setup a SIAF and commit
  11. select the #question element and insert the first quiz question
  12. listen on the #submit click and evaluate the #answer
  13. compare the #answer with the correct answer for the question
  14. store player score, and increment if answer is correct
  15. setup a quiz of 5 - 10 questions (commit everytime it works)
  16. display the next question and clear the #answer after every submission
  17. at the end of the quiz, display the player’s final score
  18. when complete, set up a github project named “DomQuiz
  19. use the git remote command to push your commits to github.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment