Added 'toList' and 'toLists' functions, with corresponding tests.