Better line-mode example