What is wrong with this code?

``` if(x = 2)
{
cout<<”The number is 2”;
}```
A. There should not be { }’s
B. A semicolon is missing in the if statement – if (x = 2 )
C. The if statement should be if ( x == 2 )
D. Nothing

C

Computer Science & Information Technology

You might also like to view...

A method name combined with its optional parameterList is called the method's ____.

A. signature B. event C. attribute D. behavior

Computer Science & Information Technology

?What is NOT a reason for adding a digital signature to a presentation?

A. ?to automatically send a presentation copy to a predetermined e-mail address B. to ?authenticate the signer of the document C. ?to ensure that content has not been changed D. ?to ensure the reader the origin of the signed document

Computer Science & Information Technology