Once you have the line of answers, you could set up a loop to go over each character in that String.
answers = answers.trim();
for (int x = 0 ; x < answers.length ; ++x)
case 'A': //do PrintStream Logic
This should work in principal, might have to play a bit.