added shebang and some better output formatting