Total beginner to programming & Scala, what would you suggest to get them started?

The construct this forces me to introduce is import, and I already only have one of those for the first half of the semester. Previously I could go through the first half of the semester, which includes expressions, basic types, conditionals, functions, sequences, and loops using basic text input and output without having a single import, so I never needed to show them that. The language keywords they needed were val, var, def, if, match, for, and while.

In the second half of the semester we do files and GUIs (with ScalaFX). I used to introduce import with the files, and they are heavily used for the GUIs. Once we get there, I don’t want to hide them in a package object because they need to know where to look in the API to find things, and having students write imports helps solidify that in their minds. I will also note we are writing scripts, so anything that isn’t in the standard library imposes a hurdle.

1 Like