Changed indentation to 4 spaces
Refactored code: removed superfluous subroutines , replaced by std lib ones
Changed the meaning of the list command, fixed typoo