Your code should work. If nothing is printed, not even "null", then you probably aren't getting to your servlet at all. If you set a break point in the servlet, is it hit? If not, your web.xml URL mapping may be wrong. (Or some other mapping file, if you're using something like Struts.)
What do you mean when you say "printed"? In most cases, System.out.println() in a servlet will write to a log file somewhere in the servlet container. Did you expect "A" to show up in the generated HTML? Or what?