Test your basic knowledge |

Javascript Basics

Subject : it-skills
Instructions:
  • Answer 50 questions in 15 minutes.
  • If you are not ready to take this test, you can study here.
  • Match each statement with the correct term.
  • Don't refresh. All questions and answers are randomly picked and ordered every time you load a test.

This is a study tool. The 3 wrong answers for each question are randomly chosen from answers to other questions. So, you might find at times the answers obvious, but you will see it re-enforces your understanding as you take the test each time.
1. To code an If statement in JavaScript






2. The string escape sequence to insert a form feed in JavaScript






3. Unlike ________________ identity operators do not perform type coercion.






4. What String object method returns a new string containing the value of the original string but in all lower case






5. Math object method used to return the lowest value for a set of supplied numbers






6. The syntax of a conditional operator






7. Statements end in JavaScript with a ________






8. Command to display a prompt






9. A _______ variable can be changed and accessed from within and without a function or object.






10. To get the text value of the control for radio buttons






11. The string escape sequence to insert a single quote in JavaScript


12. To get the current value for textboxes






13. The string escape sequence to insert a vertical tab in JavaScript






14. To code a for statement in JavaScript






15. To code a button.onclick event handler






16. To concatenate multiple parts into a string






17. To create an Array object in JavaScript






18. To get the current checked status of the control for checkboxes






19. To access the text element in a <span> tag






20. To create a function that returns a value in JavaScript






21. The _____ attribute is used to denote external file for script use






22. To set the current checked status of the control for radio buttons






23. To create a function in JavaScript






24. The valid characters for an identifier in JavaScript: Letters - Numbers - ________ and Dollar Signs






25. Math object method used to return a given number rounded to the next lowest integer value






26. String object method used to return a new string that contains part of the original string from the specified start position and up to but not including the specified stop index






27. A function that is called with a certain event occurs - e.g. button.onclick and window.onload.






28. To insert Javascript into a web page






29. To assign the value from a prompt to a string






30. To denote a string in JavaScript






31. The format to create a new Date object from a string






32. To make the browser load a new page using JavaScript






33. To get the current value of the control for a text area






34. The available get methods for a Date object: getTime() - _________ - getMonth() - getDate() - getHours() - getMinutes() - getSeconds() - getMilliseconds()






35. To get the current checked status of the control for radio buttons






36. To code a while statement in JavaScript






37. To set the control to be disabled for textboxes






38. Date object method used to return a string containing the date






39. Math object method used to return a given number raised to a given power






40. Date object method used to return a string containing the date and time






41. To set the digit precision of a decimal number






42. The string escape sequence to insert a tab in JavaScript






43. The four attributes of the <script> tag:Type - Src - _____ and Defer






44. Math object method used to return the highest value from a set of supplied numbers






45. The string escape sequence to insert a double quote in JavaScript






46. To declare a variable in JavaScript






47. Math object method used to return a given number rounded to the next highest integer value






48. To access a page element by id






49. To write text to the current element of the DOM






50. JavaScript is case _______