Adding file handling capability

File handling capability
Command line argument
Refactor

Refactor the code using sets instead of list.remove