Did you mean to have an il and and i1? I'm no C++ guru or anything, but it doesn't look like you ever declared i1 -- that's all.
alc6379
Cookie... That's it
2,820 posts since Dec 2003
Reputation Points: 186
Solved Threads: 147
how do i declare i1 ?
Wait a minnnit....
You don't know how to declare variables? What about this part in your code?
<strong>//Declare the variables</strong>
int il, i2, quotient, remainder;
You declared some variables RIGHT THERE! How could you know to initialize variables there, but then forget? Did you copy this code, or something? Without stepping too far out on a ledge, I'll bet you could initialize i1 by
//Declare the variables
int i1, i2, quotient, remainder;
Like kakilang, you used il several times instead of i[/b]1[/b]
alc6379
Cookie... That's it
2,820 posts since Dec 2003
Reputation Points: 186
Solved Threads: 147
Just a hint! Mixing up l and 1 are easy to do and hard to catch reading the code. I would use slightly more meaningful variable names like q and r. Also avoid using the often used i in loops and counters, it is another hard to read character, replace with k or such.
vegaseat
DaniWeb's Hypocrite
5,989 posts since Oct 2004
Reputation Points: 1,345
Solved Threads: 1,417