Deck 4: Java Script Operators and Data Types

Full screen (f)
exit full mode
Question
Decrement operator, ??, decreases the value of variable by what number?

A)1
B)2
C)3
D)4
Use Space or
up arrow
down arrow
to flip the card.
Question
Which right shift operator preserves the sign of the value?

A)<<
B)>>
C)<<=
D)>>=
Question
What is the output of relational operators?

A)integer
B)boolean
C)characters
D)double
Question
. Which of these is returned by "greater than", "less than" and "equal to" operators?

A)integers
B)floating - point numbers
C)boolean
D)none of the mentioned
Question
Which of these jump statements can skip processing the remainder of the code in its body for a particular iteration?

A)break
B)return
C)exit
D)continue
Question
Which of the following is not a decision making statement?

A)if
B)if-else
C)switch
D)do-while
Question
Which of the following is not a valid flow control statement?

A)exit()
B)break
C)continue
D)return
Question
What is the range of short data type in Java script ?

A)-128 to 127
B)-32768 to 32767
C)-2147483648 to 2147483647
D)none of the mentioned
Question
What is the range of byte data type in Java script?

A)-128 to 127
B)-32768 to 32767
C)-2147483648 to 2147483647
D)none of the mentioned
Question
An expression involving byte, int, and literal numbers is promoted to which of these?

A)int
B)long
C)byte
D)float
Question
What is the numerical range of a char data type in Java script?

A)-128 to 127
B)0 to 256
C)0 to 32767
D)0 to 65535
Question
Which of these coding types is used for data type characters in Java script?

A)ascii
B)iso-latin-1
C)unicode
D)none of the mentioned
Question
Which one is a valid declaration of a Boolean?

A)boolean b1 = 1;
B)boolean b2 = 'false';
C)boolean b3 = false;
D)boolean b4 = 'true'
Question
Which of these operators is used to allocate memory to array variable in Java script?

A)malloc
B)alloc
C)new
D)new malloc
Question
Which of these is an incorrect array declaration?

A)intarr[] = new int[5]
B)int [] arr = new int[5]
C)intarr[] = new int[5].
D)intarr[] = int [5] new
Question
Which of these is necessary to specify at time of array initialization?

A)row
B)column
C)both row and column
D)none of the mentioned
Question
Which of the following can be operands of arithmetic operators?

A)numeric
B)boolean
C)characters
D)both numeric & characters
Question
Modulus operator, %, can be applied to which of these?

A)integers
B)floating - point numbers
C)both integers and floating - point numbers
D)none of the mentioned
Question
Which operator is used to invert all the digits in a binary representation of a number?

A)~
B)<<<
C)>>>
D)^
Question
On applying Left shift operator, <<, on integer bits are lost one they are shifted past which position bit?

A)1
B)32
C)33
D)31
Question
Which of these operators can skip evaluating right hand operand?

A)!
B)none of the mentioned
C)&
D)&&
Question
Which of these statements are incorrect?

A)equal to operator has least precedence
B)<br>ackets () have highest precedence
C)division operator, /, has higher precedence than multiplication operator
D)addition operator, +, and subtraction operator have equal precedence
Question
Which of these selection statements test only for equality?

A)if
B)switch
C)if & switch
D)none of the mentioned
Question
. Which of these are selection statements in Java script?

A)if()
B)for()
C)continue
D)break
Unlock Deck
Sign up to unlock the cards in this deck!
Unlock Deck
Unlock Deck
1/24
auto play flashcards
Play
simple tutorial
Full screen (f)
exit full mode
Deck 4: Java Script Operators and Data Types
1
Decrement operator, ??, decreases the value of variable by what number?

A)1
B)2
C)3
D)4
1
2
Which right shift operator preserves the sign of the value?

A)<<
B)>>
C)<<=
D)>>=
>>
3
What is the output of relational operators?

A)integer
B)boolean
C)characters
D)double
boolean
4
. Which of these is returned by "greater than", "less than" and "equal to" operators?

A)integers
B)floating - point numbers
C)boolean
D)none of the mentioned
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
5
Which of these jump statements can skip processing the remainder of the code in its body for a particular iteration?

A)break
B)return
C)exit
D)continue
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
6
Which of the following is not a decision making statement?

A)if
B)if-else
C)switch
D)do-while
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
7
Which of the following is not a valid flow control statement?

A)exit()
B)break
C)continue
D)return
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
8
What is the range of short data type in Java script ?

A)-128 to 127
B)-32768 to 32767
C)-2147483648 to 2147483647
D)none of the mentioned
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
9
What is the range of byte data type in Java script?

A)-128 to 127
B)-32768 to 32767
C)-2147483648 to 2147483647
D)none of the mentioned
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
10
An expression involving byte, int, and literal numbers is promoted to which of these?

A)int
B)long
C)byte
D)float
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
11
What is the numerical range of a char data type in Java script?

A)-128 to 127
B)0 to 256
C)0 to 32767
D)0 to 65535
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
12
Which of these coding types is used for data type characters in Java script?

A)ascii
B)iso-latin-1
C)unicode
D)none of the mentioned
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
13
Which one is a valid declaration of a Boolean?

A)boolean b1 = 1;
B)boolean b2 = 'false';
C)boolean b3 = false;
D)boolean b4 = 'true'
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
14
Which of these operators is used to allocate memory to array variable in Java script?

A)malloc
B)alloc
C)new
D)new malloc
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
15
Which of these is an incorrect array declaration?

A)intarr[] = new int[5]
B)int [] arr = new int[5]
C)intarr[] = new int[5].
D)intarr[] = int [5] new
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
16
Which of these is necessary to specify at time of array initialization?

A)row
B)column
C)both row and column
D)none of the mentioned
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
17
Which of the following can be operands of arithmetic operators?

A)numeric
B)boolean
C)characters
D)both numeric & characters
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
18
Modulus operator, %, can be applied to which of these?

A)integers
B)floating - point numbers
C)both integers and floating - point numbers
D)none of the mentioned
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
19
Which operator is used to invert all the digits in a binary representation of a number?

A)~
B)<<<
C)>>>
D)^
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
20
On applying Left shift operator, <<, on integer bits are lost one they are shifted past which position bit?

A)1
B)32
C)33
D)31
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
21
Which of these operators can skip evaluating right hand operand?

A)!
B)none of the mentioned
C)&
D)&&
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
22
Which of these statements are incorrect?

A)equal to operator has least precedence
B)<br>ackets () have highest precedence
C)division operator, /, has higher precedence than multiplication operator
D)addition operator, +, and subtraction operator have equal precedence
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
23
Which of these selection statements test only for equality?

A)if
B)switch
C)if & switch
D)none of the mentioned
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
24
. Which of these are selection statements in Java script?

A)if()
B)for()
C)continue
D)break
Unlock Deck
Unlock for access to all 24 flashcards in this deck.
Unlock Deck
k this deck
locked card icon
Unlock Deck
Unlock for access to all 24 flashcards in this deck.