I had this problem once. Though i dont have a solution, it worked when i put my servlet in a package.
Try putting class a in a package. Copy to your classes dir and access via
http://localhost/servlet/package.a See if this works.
And can some one shed light on why this happens?