RosettaCodeData/Task/Arrays/Scala/arrays-2.scala
2023-07-01 13:44:08 -04:00

3 lines
138 B
Scala

val a = new collection.mutable.ArrayBuffer[Int]
a += 5 // Append value 5 to the end of the list
a(0) = 6 // Assign value 6 to element 0