更多“若有byte b=6;short s=20;则表达式b+s的值的类型是()。A.byteB.intC.shortD.char ”相关问题
  • 第1题:

    若有byte b=6;char c='c';则表达式b+c的值的类型是()。

    A.int

    B.byte

    C.char

    D.float


    答案:C

  • 第2题:

    若有float f=2.6f;short s=20;则表达式f+s的值的类型是()。

    A.float

    B.short

    C.int

    D.byte


    答案:A

  • 第3题:

    若有定义语句:int s=6;则表达式s%2+(s+1)%2的值为 。


    1

  • 第4题:

    若有char c='8';short s=20;则表达式c+s的值的类型是()。

    A.char

    B.short

    C.int

    D.byte


    答案:A

  • 第5题:

    以下代码中变量result的可能类型有哪些?byte b = 11;short s = 13;result = b * ++s;

    A.byte, short, int, long, float, double

    B.boolean, byte, short, char, int, long, float, double

    C.byte, short, char, int, long, float, double

    D.byte, short, char

    E.int, long, float, double


    正确答案:E