0 votes
in JavaScript by
What will be the output of the following JavaScript code?

functioncomparison()  

{  

int number=10;  

if(number==="10")  

returntrue;  

else  

returnfalse;  

}  

a) True

b) false

c) runtime error

d) compilation error

1 Answer

0 votes
by

Answer: A

Reason: The "===" is known as a strict comparison operator which will result as true when the data-type, content of operand are the same. For example, In JavaScript, two strings can be considered as strict equal when the length, sequence, and same characters, are the same when compared to each other.

Related questions

0 votes
asked Mar 21, 2021 in JavaScript by rajeshsharma
0 votes
asked Mar 20, 2021 in JavaScript by sharadyadav1986
...