This week's book giveaway is in the Jobs Discussion forum. We're giving away four copies of Java Interview Guide and have Anthony DePalma on-line! See this thread for details.

I'm trying to write a method that accepts a string of names followed by integers, and the names alternate between boys and girls.
For examples: "Mark 41 Jennifer 22 Daniel 49 Jessica 67 Joshua 87"
The output should be:
3 boys, 2 girls
boys sum = 177
girls sum = 89

I'm having trouble just figuring out first of all how to alternate, and then how to get past the names to the integers.
Any help is appreciated, thank you!