Font size
Worksheets[Generation Girl] - Day 1 (Post Test)
Total questions: 15
Worksheet time: 7mins
What is the symbol that we use to concat a word between a sentence?
!
#
$
@
Below are file extensions that are used in Kotlin, except :
.kt
.ktm
.ktn
.kts
Can we run both java and kotlin files in the same Android project?
Yes
No
How to write a correct String in Kotlin?
val name1: String = "Elsa"
val name2: String? = "Anna"
val name3 = "Olaf"
All answers are correct
Which uses of elvis operation is correct?
a ?: -1
a :? -1
a ?:: -1
a ::? b
Which of the following is not a type of the Integer data type?
Byte
Short
Long
Bit
The operator used to calculate the remainder of the quotient is ?
Mod (%)
Div (/)
Sub (-)
Plus (+)
The conditional operator that evaluates to true if both statements are true is ...
AND
NOT
OR
TRUE
What is the result after executing those code?
TRUE
FALSE
Operator '==' cannot be applied to 'Int' and 'Float'
Operator '==' cannot be applied to 'Int' and 'Double'
Will it generate an ERROR?
YES
NO
Which conditional statements will return true?
if(noTobacco && noAlcohol)
if(veganDiet || ketogenicDiet)
if(veganDiet && ketogenicDiet)
if(noTobacco || veganDiet)
What is the result after executing those code?
selection 1
selection 2
Using kotlin, what is the proper way to define a variable with a specific data type?
var myName: String = "Generation Girl"
var myAge= Int:18
Float myWage = 100.0
var Boolean isPerfect = True
Will that block of code generate an error?
Yes
No
Keyword that used to stop a for loop is
stop
continue
pause
break
