Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Branch: master
Fetching contributors…

Cannot retrieve contributors at this time

40 lines (34 sloc) 1.682 kB
package s99
import Solutions._
trait ListsSolutions {
def last[T](list: List[T]): T = ???
def penultimate[T](list: List[T]): T = ???
def nth[T](n: Int, list: List[T]): T = ???
def length[T](list: List[T]): Int = ???
def reverse[T](list: List[T]): List[T] = ???
def isPalindrome[T](list: List[T]): Boolean = ???
def flatten(list: List[Any]): List[Any] = ???
def compress[T](list: List[T]): List[T] = ???
def pack[T](list: List[T]): List[List[T]] = ???
def encode[T](list: List[T]): List[(Int, T)] = ???
def encodeModified[T](list: List[T]): List[Any] = ???
def decode[T](list: List[(Int, T)]): List[T] = ???
def encodeDirect[T](list: List[T]): List[(Int, T)] = ???
def duplicate[T](list: List[T]): List[T] = ???
def duplicateN[T](n: Int, list: List[T]): List[T] = ???
def drop[T](n: Int, list: List[T]): List[T] = ???
def split[T](n: Int, list: List[T]): (List[T], List[T]) = ???
def slice[T](i: Int, j: Int, list: List[T]): List[T] = ???
def rotate[T](n: Int, list: List[T]): List[T] = ???
def removeAt[T](i: Int, list: List[T]): (List[T], T) = ???
def insertAt[T](t: T, i: Int, list: List[T]): List[T] = ???
def range[T](i: Int, j: Int): List[Int] = ???
def randomSelect[T](n: Int, list: List[T]): List[T] = ???
def lotto[T](i: Int, j: Int): List[Int] = ???
def randomPermute[T](list: List[T]): List[T] = ???
def combinations[T](n: Int, list: List[T]): List[List[T]] = ???
def group3[T](list: List[T]): List[List[List[T]]] = ???
def groups[T](ns: List[Int], list: List[T]): List[List[List[T]]] = ???
def lsort[T](list: List[List[T]]): List[List[T]] = ???
def lsortFreq[T](list: List[List[T]]): List[List[T]] = ???
}
Jump to Line
Something went wrong with that request. Please try again.