I am enrolled in a distance education program with a major in C++. I've been working on this problem for over a month, and am just about at my wit's end. The problem is: "Write a program that reads 20 digit characters (i.e. characters in the range '0' ...'9') and counts the number of digits that are either 3,5, or 6 and that are either 1,4, or 9. Those are two separate counts. All other digits should be ignored. Make use of the SWITCH statement." If someone is willing to help me with this, I can e-mail the program I've written so far.
To those of you who have contacted me, I'm really not sure where the problem lies, since it seems to require both a "counter" (this is what my instructor calls it, a term that I have not been able to find in any one of a half dozen reference books) and a switch statement. What happens at this point is that the program compiles and runs beautifully, but after I enter the numbers (as characters rather than integers) the program skips directly to the first default and then miscounts the second series of numbers.
I will be glad to post the latest version if someone will tell me how to do that. I can't figure out how to attach anything to this message. Should I just go ahead and post my program as another message, referenced to this one?
And by the way, thanks for taking an interest.