supereater14 Posted April 7, 2010 Author Share Posted April 7, 2010 not according to my c++ tome of goodness (the colorful one) it works my way in all my other programs Quote Link to comment Share on other sites More sharing options...
requiem Posted April 7, 2010 Share Posted April 7, 2010 ifstream fin ("input.txt"); That's the shorthand method. It should work either way. ie: ifstream fin; fin.open("input.txt"); Quote Link to comment Share on other sites More sharing options...
supereater14 Posted April 7, 2010 Author Share Posted April 7, 2010 so why isn't it working? Quote Link to comment Share on other sites More sharing options...
exxon Posted April 7, 2010 Share Posted April 7, 2010 are you still using the code posted on the previous page? your for loops are wrong. for(int b = 0; b == 99; b++) That doesnt do anything. You initialize b to 0 and check if b is equal to 99. since its not equal your loop never starts. and one of those loops controls the switch statement which controls the output. what you want is for( int i = 0; i < 100; i++ ) of course this is assuming that you're still using the code you posted before. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.