Is there a way to deconstruct a pair and define bo...
# announcements
f
Is there a way to deconstruct a pair and define both a
var
and
val
in the same call? Or reassign and declare in the same call? Currently I have to do this and its not so nice.
Copy code
var line = input

val (lineWithoutParenthesis, parenthesis) = extractParenthesis(line)
line = lineWithoutParenthesis.trim()
val (lineWithoutAlternatives, alternativeStrings) = extractAlternativeStrings(line)
line = lineWithoutAlternatives.trim()