Scala Tutorials
- Basic Scala Tutorial
About
Tweet
14
Return multiple variables
It is possible to return multiple variables using Tuples
See Also
opens in new page
More on Tuples
def swap(x:String, y:String) = (y, x) val (a,b) = swap("hello","world") println(a, b)
Theme
Monokai
Solarized Dark
Eclipse
Code editor is using
Scalakata.com
written by
Guillaume Massé
TOC
◀ Prev
Next ▶
×
Table of Contents