Identify Datatype.

Q7. Given the following set of identifiers:

byte b;

char ch;

short sh;

int intval;

long longval;

float fl;

Identify the datatype of the following expressions:

a.)’a’-3     

b.) intval * longval – ch  

c.) fl + longval / sh

Ans.

a.) int because

b.) long because

c.) float because

Leave a Reply

Your email address will not be published. Required fields are marked *

19 Views
%d bloggers like this: