Create a normal enum, in the companion object put ...
# getting-started
k
Create a normal enum, in the companion object put a function
fromNumber
or something like that.
👍 1
b
Even better, put a
operator fun invoke
in the companion object!