Changed Iterator to take immutable.Seq instead of mutable.Seq. Also changed Pi tutorial to use Vector instead of Array
This commit is contained in:
parent
d859a9cb13
commit
1eea91abfa
2 changed files with 5 additions and 4 deletions
|
|
@ -63,8 +63,8 @@ object Pi {
|
|||
|
||||
// create the workers
|
||||
val workers = {
|
||||
val ws = new Array[ActorRef](nrOfWorkers)
|
||||
for (i <- 0 until nrOfWorkers) ws(i) = actorOf[Worker].start
|
||||
var ws = Vector[ActorRef]()
|
||||
for (i <- 0 until nrOfWorkers) ws = ws :+ actorOf[Worker].start
|
||||
ws
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue