KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I never thought I would be asking such a simple question but how do I update array element in scala I have declared inner function inside my Main object and I have something like this object Main { def main(args: Array[String]) { def miniFunc(num: Int) { val myArray = Array[Double](num) for(i <- /* something*/) myArray(i) = //something } } } but I always get an exception, Could someone explain me why and how can I solve this problem?
Tags (comma-separated)
Save Edits
Cancel