Skip to content

Commit a0a3172

Browse files
committed
fix
1 parent b4ba698 commit a0a3172

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

chapter_3/exercise_3_05/itob.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ void itob(int n, char s[], int b)
3939
{
4040
s[i++] = itoc(abs(n) % b);
4141
n /= b;
42-
} while (n /= b);
42+
} while (n);
4343

4444
switch (b)
4545
{

0 commit comments

Comments
 (0)