Lakshya Education MCQs

Question: What is the function of the parseInt() method?
Options:
A.Parses a datatype and stores in an integer
B.Parses a string and returns an integer
C.Parses an integer and returns a string
D.None of the mentioned
Answer: Option B

Submit Answer & Explaination

Earn Reward Points by submitting Detailed Explaination for this Question

More Questions on This Topic :

Question 1. What does it indicate when the radix value is 16?
  1.    String begins with 0x
  2.    String begins with 0
  3.    String begins with 0P
  4.    String begins with FF
Answer: Option A
Question 2. What is the purpose of the radix parameter in the parseInt() method?
  1.    Numeral system not to be used
  2.    Numeral system to be used
  3.    Convertion mode
  4.    None of the mentioned
Answer: Option B
Question 3. What will be the radix value of the parseInt() method when the string begins with 0?
  1.    6
  2.    7
  3.    8
  4.    9
Answer: Option C
Question 4. What will be the radix value if the string begins with 0x?
  1.    13
  2.    14
  3.    15
  4.    16
Answer: Option D
Question 5. What will happen if the radix parameter of the parseInt() function is omitted?
  1.    Runs in assumption
  2.    Throws exception
  3.    Aborts
  4.    Taken as 0
Answer: Option A
Question 6. To which of the following object does the print() method belong to?
  1.    window
  2.    document
  3.    hash
  4.    none of the mentioned
Answer: Option A

Check all Questions in this Topic : Click HERE