class BackIntSorter
-special AbstractSorter[Int]
- redef meth compare(a: Int, b: Int): Int
+ super AbstractSorter[Int]
+ redef fun compare(a: Int, b: Int): Int
do
return b <=> a
end
end
class DecimalSorter
-special AbstractSorter[Int]
- redef meth compare(a: Int, b: Int): Int
+ super AbstractSorter[Int]
+ redef fun compare(a: Int, b: Int): Int
do
return (a%10) <=> (b%10)
end
init do end
end
-meth get_an_array(nb: Int): Array[Int]
+fun get_an_array(nb: Int): Array[Int]
do
var res = new Array[Int].with_capacity(nb)
var j = 64