Kotlin Discussions
In Kotlin, can a function return either String or Int?
Support
jstuyts
February 20, 2020, 11:43am
2
See this thread for the discussion about union types:
Union types
1 Like
show post in topic
Related topics
Topic
Replies
Views
Activity
Implementing an alternative to union types
1
153
August 20, 2024
Is it possible to declare a variable with two types in Kotlin, like val x: Int or String?
Language Design
4
22998
February 10, 2021
Union types
Language Design
130
120224
June 24, 2024
Multiple types like in TypeScript
Language Design
10
10853
June 23, 2020
Kotlin Feedback After Project
Language Design
6
1580
April 20, 2017