lunduniversity / introprog

Teaching material for "Introduction to Programming using Scala" at Lund University, LTH. http://cs.lth.se/pgk/
140 stars 167 forks source link

Quickref - add refrence to scala.util.Random #698

Closed valterbergstrand closed 1 year ago

valterbergstrand commented 1 year ago

I could not find an declaration and description of scala.util.Random in the quickref. This is something I think should be included, but I don't know where it should be placed.

valterbergstrand commented 1 year ago

more specifically, the method scala.util.Random.nextInt

bjornregnell commented 1 year ago

Thanks for the issue.

It is actually part of the Java JDK and just delegated from scala.util.Random to java.util.Random but that is not easy to know if you are not used to look into the Java part of the quickref.

I guess next year we should restructure the whole quickref to have more Scala and less Java and just focus the Java part on JDK stuff that is interesting to use from Scala. What do you think @valterbergstrand ?

In any case util.Random should be in the Scala part....