Quiz On JavaScript Skills! Trivia

Approved & Edited by ProProfs Editorial Team
The editorial team at ProProfs Quizzes consists of a select group of subject experts, trivia writers, and quiz masters who have authored over 10,000 quizzes taken by more than 100 million users. This team includes our in-house seasoned quiz moderators and subject matter experts. Our editorial experts, spread across the world, are rigorously trained using our comprehensive guidelines to ensure that you receive the highest quality quizzes.
Learn about Our Editorial Process
| By Csection
C
Csection
Community Contributor
Quizzes Created: 1 | Total Attempts: 253
Questions: 11 | Attempts: 253

SettingsSettingsSettings
Quiz On JavaScript Skills! Trivia - Quiz



Questions and Answers
  • 1. 

    Java Script File Has An Extension Of

    • A.

      .Java

    • B.

      .Js

    • C.

      .javascript

    • D.

      .xml

    Correct Answer
    B. .Js
    Explanation
    The correct answer is ".Js" because JavaScript files typically have a file extension of ".js". This file extension helps to identify and differentiate JavaScript files from other types of files.

    Rate this question:

  • 2. 

    The Tag is used To Give Heading To The Table.

    • A.

      Head

    • B.

      Td

    • C.

      Th

    • D.

      Caption

    Correct Answer
    D. Caption
    Explanation
    The "caption" tag is used to provide a heading or title to a table. It is typically placed at the top of the table and helps to provide a brief description or summary of the table's content. This tag is used to improve the accessibility and understanding of the table for users.

    Rate this question:

  • 3. 

    IsNaN() Evaluates And Argument To Determine if Given Value

    • A.

      Is Not a Null

    • B.

      Is Not a Number

    • C.

      Is Not a New Object

    • D.

      None Of The Above

    Correct Answer
    B. Is Not a Number
    Explanation
    The isNaN() function is used to determine if a given value is not a number. It returns true if the value is not a number and false if it is a number. This function is often used to validate user input in forms or to check if a mathematical operation resulted in a valid number.

    Rate this question:

  • 4. 

    Function is Used To Parse a String To Int

    • A.

      Integer.Parse

    • B.

      Int.Parse

    • C.

      Parse.Int

    • D.

      None

    Correct Answer
    B. Int.Parse
    Explanation
    Int.Parse is the correct answer because it is a function that is used to convert a string to an integer. By using Int.Parse, you can take a string input and convert it into an integer data type. This function is commonly used in programming languages to handle situations where you need to convert user input or data from a file into numerical values for calculations or comparisons.

    Rate this question:

  • 5. 

    Which Of The Dialog Box Display a Message And a Data Entry Field?

    • A.

      Alert()

    • B.

      Prompt()

    • C.

      Confirm()

    • D.

      Msg()

    Correct Answer
    B. Prompt()
    Explanation
    The prompt() dialog box displays a message and a data entry field. This allows the user to enter some input in response to the message displayed. The other options, such as alert(), confirm(), and msg(), do not have a data entry field and are used for displaying messages or asking for confirmation from the user.

    Rate this question:

  • 6. 

    Event is Used To Check An Empty Text Box.

    • A.

      Onclick()

    • B.

      OnFocus()

    • C.

      OnBlur()

    • D.

      None

    Correct Answer
    C. OnBlur()
    Explanation
    The onBlur() event is used to check if a text box is empty when the user moves away from it. This event is triggered when the user clicks outside of the text box or tabs away from it. It allows for validation or any other action to be performed to ensure that the text box is not left empty. The onClick() event is triggered when the user clicks on the text box, OnFocus() event is triggered when the text box receives focus, and "None" indicates that none of these events are used to check an empty text box.

    Rate this question:

  • 7. 

    Method Prompt() Contain ........Number of Parameters.

    • A.

      One

    • B.

      Two

    • C.

      Three

    • D.

      Zero

    Correct Answer
    B. Two
    Explanation
    The method Prompt() contains two parameters.

    Rate this question:

  • 8. 

    GetMonth() returns The Month as

    • A.

      Int

    • B.

      Float

    • C.

      Char

    • D.

      String

    Correct Answer
    A. Int
    Explanation
    The getMonth() function returns the month as an integer. This means that the value returned by the function will be a whole number representing the month, such as 1 for January, 2 for February, and so on. It will not return a float (decimal number), character, or string.

    Rate this question:

  • 9. 

    If Button is clicked .......Event Handler is invoked.

    • A.

      OnSubmit()

    • B.

      OnLoad()

    • C.

      IsPostBack()

    • D.

      Onclick()

    Correct Answer
    D. Onclick()
    Explanation
    When a button is clicked, the event handler associated with that button is invoked. In this case, the correct answer is "Onclick()" because it represents the event that is triggered when the button is clicked. The other options, "OnSubmit()", "OnLoad()", and "IsPostBack()", do not specifically refer to the event of clicking a button.

    Rate this question:

  • 10. 

    A Function Associated With An object is Called

    • A.

      Function

    • B.

      Method

    • C.

      Link

    • D.

      None

    Correct Answer
    B. Method
    Explanation
    A function associated with an object is called a method. In object-oriented programming, methods are functions that are defined within a class and are used to perform specific actions or operations on the object. Methods can access and manipulate the data within the object, and they are typically called using the object's name followed by the method name, using the dot notation.

    Rate this question:

  • 11. 

    Inside which HTML element do we put the JavaScript?

    • A.

      Js

    • B.

      JavaScript

    • C.

      Script

    • D.

      Scripting

    Correct Answer
    B. JavaScript
    Explanation
    The correct answer is "script". This is because the "script" element is specifically designed to hold JavaScript code within an HTML document. It is used to embed or reference external JavaScript files, or to directly include JavaScript code within the HTML file itself.

    Rate this question:

Quiz Review Timeline +

Our quizzes are rigorously reviewed, monitored and continuously updated by our expert board to maintain accuracy, relevance, and timeliness.

  • Current Version
  • Mar 15, 2023
    Quiz Edited by
    ProProfs Editorial Team
  • Jul 26, 2016
    Quiz Created by
    Csection
Back to Top Back to top
Advertisement
×

Wait!
Here's an interesting quiz for you.

We have other quizzes matching your interest.