echo "Enter path of backup file e.g /tmp/backup/etc.tar.gz : "
    read PATH    #input was /tmp/backup/etc.tar.gz
    echo "Enter directory: " 
    read DIR    #input was /root/testing
    sudo tar -zvxf "$PATH" -C "$DIR"
when I ran the script, it said that the command was not found. I tried using whatever kind of brackets for the variables but still not working. Any help?
However when I ran the command tar -zvxf /tmp/backup/etc.tar.gz -C /root/testing , it worked.
 
    