Kotlin 针对 Java 开发人员的测验

  1. Kotlin is ___ interoperable with the Java programming language.

  2. True or false? The conversion process in Android Studio produces functionally equivalent Kotlin code that compiles and runs.

  3. Match the descriptions of how Kotlin generates in JVM bytecode with the correct annotations.

    Each answer only matches one item.

    Generates static members and methods

    Generates overloaded methods for functions that have default values

    Changes the name of getters and setters

    Exposes a property directly as a field, rather than via getters and setters

    Declares checked exceptions

  4. What are different ways you can incorporate Kotlin into an existing Android app written in the Java programming language?

    Choose as many answers as you see fit.

  5. Which of the following statements are true in regards to Kotlin providing null safety?

    Choose as many answers as you see fit.

  6. Assume you have declared a function in Kotlin that contains default values for all three of its parameters. Which of these statements are true about calling such a function?

    Choose as many answers as you see fit.