index
:
k&r-exercises
master
Solutions to the exercises in K&R from my days of learning C.
summary
refs
log
tree
commit
diff
stats
log msg
author
committer
range
diff options
context:
1
2
3
4
5
6
7
8
9
10
15
20
25
30
35
40
space:
include
ignore
mode:
unified
ssdiff
stat only
Diffstat
-rw-r--r--
3/4.c
2
1 files changed, 1 insertions, 1 deletions
diff --git a/3/4.c b/3/4.c
index 1ba196c..5ddf2ef 100644
--- a/
3/4.c
+++ b/
3/4.c
@@ -27,7 +27,7 @@ void itoa(int n, char s[]) {
i = 0;
- if (n >= 0) {
+ if (n != INT_MIN) {
do {
s[i++] = n % 10 + '0';
} while ((n /= 10) > 0);