Javascript Events, timers and form inputs Speed Writer This little application tests how fast a user can type a certain

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899603
Joined: Mon Aug 02, 2021 8:13 am

Javascript Events, timers and form inputs Speed Writer This little application tests how fast a user can type a certain

Post by answerhappygod »

Javascript Events Timers And Form Inputs Speed Writer This Little Application Tests How Fast A User Can Type A Certain 1
Javascript Events Timers And Form Inputs Speed Writer This Little Application Tests How Fast A User Can Type A Certain 1 (288.33 KiB) Viewed 7 times
Javascript Events, timers and form inputs Speed Writer This little application tests how fast a user can type a certain number of words. Start Screen Present the user with a range slider that has a minimum of 5 and a maximum of 10. The value on this slider sets the difficulty level of the game. It relates to the number of words that a user must type. Provide a "Begin" button that sets the difficulty value and starts the game. These interface elements have already been created in HTML for you When the difficulty has been selected, clear the UI of all components Game Screen Display a paragraph that contains a word that the user must type and provide a text field where the user can type in the word. Set focus to the textfield. As the user types the word, check to see if it was right. If the word was correct, the user gets presented with another word. This process continues for a total of 5-10 words (Use the value the user set in the Start scre When the last word is successfully submitted, show the user the total time, in seconds, taken to complete the interaction. If the user takes more than 20 seconds, show a GAME OVER message, prevent the user from entering words and change the text to red and 32px Hints: Use the keyup event to check when a user pressed a key Use an array to hold all possible words. You do NOT need loops here. Let the keyup event trigger the presentation of the next word when the current word has been spelled correctly. Remember to clear your timers and remove the event listeners when the game is completed. var wordArray = [ "once", "upon", "a", "time", . "was", "doing", "Javascript", "Assignment", "3" ]; Use a variable to keep track of the current word's index in the array. This is helpful to control which word the user is presented with. Begin
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply