Contents

All the following are logical operators except………
a) NOT                                  
b) AND
c) OR                                     
d) =

d

For A=3 and B=7 which evaluates to true…….
a) !(A<B)                              
b) !(B<6>
c) (A=3)&&(B=5)               
d) (A=B)||(A>B)

b

Which is an example of multiple branches from single expression?
a) If statement                    
b) switch statement
c) while loop                        
d) all of these

b

What is difference between x=1 and x==1?
a) they are same 
b) x==1 adds 1 to x
c) x=1 is assignment, x==1 is equal
d) x==1 is assignment and x=1 is equivalence

c

Will document. Write(++x) give different result to document. Write(x++)?
a) yes                                    
b) no
c) only if x>y                       
d) only if x is positive

a

If x=8 and y=4, then x%y?
a) 8                                                        
b) 4
c) 2                                                        
d) 0

d