单项选择题Kotlin中哪个关键字用于声明一个数据类()

A.data
B.model
C.struct
D.type


您可能感兴趣的试卷

你可能感兴趣的试题

1.单项选择题Kotlin中哪个关键字用于声明一个单例对象()

A.singleton
B.object
C.unique
D.instance

2.单项选择题Kotlin中哪个关键字用于声明一个开放类()

A.open
B.public
C.class
D.external

3.单项选择题Kotlin中类成员默认是什么访问权限()

A.public
B.private
C.protected
D.internal

4.单项选择题Kotlin中使用哪个关键字来创建一个类()

A.class
B.type
C.struct
D.model

5.单项选择题Kotlin中哪个循环可以用来遍历区间()

A.for-in
B.while
C.do-while
D.foreach

6.单项选择题Kotlin中表示一个区间的语法是什么()

A.[start..end]
B.start..end
C.(start,end)
D.start to end

7.单项选择题Kotlin中使用哪个关键字来实现条件判断()

A.if
B.switch
C.case
D.when

8.单项选择题Kotlin中,哪个类表示单精度浮点型()

A.int
B.Integer
C.Float
D.double

10.单项选择题在Kotlin中,使用哪个关键字声明不可变变量()

A.val
B.var
C.const
D.final