Scala Stack :() method with example
In Scala, scala.collection.mutable implements Stack data structure. The :\ method applies a binary operator to a start value and all elements of this traversable or iterator, going right to left.
Method Definition – def :\[B](z: B)(op: (A, B) ? B): B
Returns – the result of inserting op between consecutive elements of this traversable or iterator.