• 2022-06-12
    若将int、long、float等类型的数据进行混合运算,其结果的数据类型是:(  )
  • double

    内容

    • 0

      如果一个表达式中,有int类型数据,float类型数据,char类型数据,double类型数据的混合运算,那么最终结果的类型是( )? A: Int B: float C: cha D: double

    • 1

      若干个int型、char型数据进行算术运算,其结果的数据类型是 。 A: int B: char C: long D: double

    • 2

      在C语言中,不同类型数据混合运算时,要先转换成同一类型后进行运算。设一表达式中包含有int、long、unsigned和char类型的变量和数据这四种类型数据的转换规律是⑵()。 A: int→unsigned→long→char B: char→int→long→unsigned C: char→int→unsigned→long D: char→unsigned→long→int

    • 3

      【填空题】在 Java 中, 基本数据类型有: byte 、 short 、 int 、 long 、 float 、 double 、 char 、 boolean。其中, byte 类型数据占 ______ 个字节, short 类型数据占 ______ 个字节, int 类型数据占 ______ 个字节, long 类型数据占 ______ 个字节,float 类型数据占 ______ 个字节,double 类型数据占 ______ 个字节, char 类型数据占 ______ 个字节, boolean 类型数据占 ______ 个字节

    • 4

      如果int与float类型变量混合运算,则先把int转换成float,结果为float。