Scala String Get Char

[Solved] Scala String Get Char | Scala - Code Explorer | yomemimo.com
Question : scala string get char

Answered by : sasso

scala> "hello"(0)
res1: Char = h
scala> "hello"(1)
res2: Char = e

Source : https://www.oreilly.com/library/view/scala-cookbook/9781449340292/ch01s10.html | Last Update : Wed, 02 Jun 21

Answers related to scala string get char

Code Explorer Popular Question For Scala