Tumbleweed:
Do I need to use a bunch of if statements instead, or put switch cases inside fewer ifs and whiles?
Or are you saying it compiled but didn't actually work? Well it would be clearer to say so, and demonstrate conclusively in what way it didn't work.