added else function;better file handling(nice one liner now possible with close included)