Development - Java Script - Statements Question And Answers

Executable single line of Script is called as _________________.

A.  Statement in JavaScript

B.  Breakpoint in JS

C.  Line in JS

D.  None of these

View Answer  

JavaScript Statements are executed by ________ .

A.  Server

B.  JVM

C.  Compiler

D.  Browser

View Answer  

Java Statement terminated by ______________ ,

A.  Slash

B.  Semicolon

C.  Full Stop

D.  Comma

View Answer  

JavaScript code contain sequence of ___________.

A.  HTML Tags

B.  All of these

C.  Method Calls

D.  Executable Statements

View Answer  

Which of the following statement is used to declare variable in JavaScript ?

A.  Assignment Statement

B.  Conditional Statement

C.  Executable Statement

D.  Declaration Statement

View Answer  

____________ is used to assign value to the variable.

A.  Assignment Statement

B.  Declaration Statement

C.  Conditional Statement

D.  Executable Statement

View Answer  

JavaScript Statement may contain HTML Tags. Say True/False.

A.  False

B.  True

C.  

D.  

View Answer  

JavaScript is Case Sensitive !!Say True or False

A.  False

B.  True

C.  

D.  

View Answer  

It is not necessary to write Semicolon at the end of JS statement !!

A.  Yes

B.  No

C.  

D.  

View Answer  

Multiple JS statements are written inside pair of ________ to form a statement block.

A.  Pair of Square Brackets

B.  Pair of Round Brackets

C.  Pair of Curly braces

D.  None of these

View Answer  

Group of JavaScript Statements is called as _________.

A.  Statement Block

B.  Group

C.  Cluster

D.  Code Block

View Answer  

Java Script have following type of Comment(s) -

A.  Single Line Comment/Multiple Line Comments

B.  Enhanced Comments

C.  HTML Style Comment

D.  All the Above

View Answer  

Single Line Comment Starts with _________ Symbol.

A.  "\"

B.  "//"

C.  "$$"

D.  "#"

View Answer  

Which of the following is considered as End of Single line comment ?

A.  End of Line

B.  Semicolon

C.  End of Statement

D.  "*/" Symbol

View Answer  

Comments in JS are ignored by ____________.

A.  Compiler

B.  Operating System

C.  JVM

D.  Browser

View Answer  

Comment Statement is _________________ type of statement.

A.  Executive

B.  Non Important

C.  Non Executable

D.  Non Usable

View Answer  

If the values on either side of '+' operator are numerical values then ___________.

A.  values are concatenated together.

B.  values are added together

C.  None of These

D.  

View Answer  

Person XYZ wrote his name and date of code creation at the start , What kind of comment he has written ?

A.  Functional Comment

B.  Code Hiding Comment

C.  Documentation Comment

D.  None of These

View Answer  

In multiple line comment , End of the comment is specified by ________ Symbol.

A.  //

B.  */

C.  *

D.  \

View Answer  

Which of the following is not a compound assignment operator.

A.  ===

B.  

C.  +=

D.  >>=

View Answer  

If a string cannot be converted to a number __________ will be returned.

A.  NaN

B.  Infinite

C.  Null

D.  Zero

View Answer  

JS Comment can be used for following purposes

A.  to Hide Non-usable line.

B.  to Hide Non-usable Multiline Code

C.  used for Documentation

D.  All of these

View Answer  

What will be printed on the screen ? Var3 =100101010

A.  1001020

B.  130

C.  10030

D.  100101010

View Answer  

During addition of two numbers , suppose one of the number is NaN then output of the following code will be ?

A.  NaN

B.  Zero

C.  Infinite

D.  Null

View Answer  

+Infinity in JS gets added with +Infinity then output of the code will be -

A.  NaN

B.  +Infinity

C.  -Infinity

D.  

View Answer  

-Infinity in JS gets added with -Infinity then output of the code will be.

A.  +Infinity

B.  NaN

C.  -Infinity

D.  

View Answer  

-Infinity in JS gets added with +Infinity then output of the code will be.

A.  NaN

B.  +Infinity

C.  -Infinity

D.  

View Answer  

var str = "Str"; var num = 10; var output = str + num; What will be the value of Variable 'output' ?

A.  Nothing will be printed

B.  Str10

C.  Null

D.  NaN

View Answer  

A Simple Page What will be printed ?

A.  "Compile Error" will be printed

B.  Nothing will be printed

C.  None of these

D.  

View Answer  

/* This is Simple Comment */ This is the example of ____________ Comment.

A.  Single Line Comment

B.  Multiple Line Comment

C.  

D.  

View Answer