progs/lecture3.scala
changeset 418 fa7f7144f2bb
parent 375 ddda2e76a40f
child 448 db2a3e3287a9
equal deleted inserted replaced
417:29fc780ca130 418:fa7f7144f2bb
     1 // Scala Lecture 3
     1 // Scala Lecture 3
     2 //=================
     2 //=================
       
     3 
     3 
     4 
     4 
     5 
     5 // naive quicksort with "On" function
     6 // naive quicksort with "On" function
     6 
     7 
     7 def sortOn(f: Int => Int, xs: List[Int]) : List[Int] = {
     8 def sortOn(f: Int => Int, xs: List[Int]) : List[Int] = {