Simplified line function (with sed its only 1 command, instead of 2)