added helper method to check if the args are correct, detect wave file, and get file name from file path. Also, added conditions for the inputs