I see it's possible to return values from if, try-...
# language-proposals
j
I see it's possible to return values from if, try-catch and several other statements, example:
Copy code
val k = try {
			"2"
		} catch(e: Exception) {
			"3"
		}
Is there a reason I can't do this with a for-loop, while-loop or do-while-loop ?
🙌 1