changed output format and fixed -l