Made RandomAccessList extend Seq instead of just Iterable

Added explicit types to test to check that higher-order functions return
the right type of collection.