How are the classes created?

Report a typo

Consider the classes below:

class A {
    var a: Int = 0
}

class B(var b: Int)

class C {
    var c: Int
    
    constructor(c: Int) {
        this.c = c
    }
}

Match the classes and their constructor types.

Match the items from left and right columns
A
B
C
Default
Primary
Secondary
___

Create a free account to access the full topic