US05-SQ-02

Updated code for US05 according code review notes 
what will happen if the file cannot be created, in this place it is important to handle exceptions to avoid unexpected errors