☰
Debian Codegraph
@
1.7.0-1
/
/
doc
/
tutorial_src
/
words3.c
☽
☼
doc/tutorial_src/words3.c
code
plain
raw
symbols
SCIP
ISC
2006-2022, Cgreen Development Team and contributors
debian/copyright
1
#include
<string.h>
2
3
int
split_words
(
char
*sentence) {
4
int
i, count =
1
;
5
for
(i =
0
; i <
strlen
(sentence); i++) {
6
if
(sentence[i] ==
' '
) {
7
sentence[i] =
'\0'
;
8
count++;
9
}
10
}
11
return
count;
12
}