in Education by
What will be the radix value if the string begins with 0x? (a) 13 (b) 14 (c) 15 (d) 16 This question was addressed to me during a job interview. The origin of the question is Parsing Values using JavaScript in chapter Parsing, Benchmarking and Logging of JavaScript Select the correct answer from above options JavaScript questions and answers, JavaScript questions pdf, JavaScript question bank, JavaScript questions and answers pdf, mcq on JavaScript pdf, JavaScript questions and solutions, JavaScript mcq Test , Interview JavaScript questions, JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)

1 Answer

0 votes
by
The correct choice is (d) 16 To explain I would say: If the string begins with 0x, then the radix value will be 16. If the string begins with “0”, the radix is 8 (octal). If the string begins with any other value, the radix is 10 (decimal).

Related questions

0 votes
0 votes
    A hexadecimal literal begins with __________ (a) 00 (b) 0x (c) 0X (d) Both 0x and 0X The ... , JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 24, 2021 in Education by JackTerrance
0 votes
    The function definitions in JavaScript begins with _____________ (a) Identifier and Parentheses (b) Return type and ... for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 24, 2021 in Education by JackTerrance
0 votes
    What is the purpose of the radix parameter in the parseInt() method? (a) Numeral system not to be ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 23, 2021 in Education by JackTerrance
0 votes
    Which of these clause will be executed even if no exceptions are found? (a) throws (b) finally (c ... JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 25, 2021 in Education by JackTerrance
0 votes
    Which of these events will be notified if scroll bar is manipulated? (a) ActionEvent (b) ComponentEvent (c ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 24, 2021 in Education by JackTerrance
0 votes
0 votes
0 votes
    If the window has child windows, how will the browsing histories be affected? (a) Numerically interleaved ( ... Questions for Interview, JavaScript MCQ (Multiple Choice Questions)...
asked Oct 23, 2021 in Education by JackTerrance
...