How can i add an item using loop in ListBuffer of tuples using Scala? I have declared the List as:
val listV = new ListBuffer[(String,Int)]();
On adding item like this:
listV += ("a",1)
gives an error of : type mismatch as following
[error] found : String("a")
[error] required: (String, Int)
[error] listV += ("a",1)
[error] ^
[error] one error found
Any suggestions to resolve this ? Thanks in anticipation