Improved ls example, added python version