If you ever are not sure of the path to one of your scripts of files (.htpasswd), you can easily find out by creating a new PHP file, and then copying the following code into the file:
After you save the file, view it in your browser and you will see the location of your file. No more guessing if it is /home/username/public_html/ or some other naming convention that your host might use.