Student report, cc4e/lectures/KR-1.pptx. My edit in (...).
With deep respect for Dr. Chuck.
In reviewing the presentation, I found the following errors:
On slides 5, 9 in the listings kr_01_01.c, kr_01_4.c "import" is used instead of the keyword "include"
On slide 5 in the listing kr_01_01.c, a double slash (%s\\n) is inserted in line 7 which breaks the '\n' operator
On slide 10 in listing kr_01_05.c, there is a useless variable len in the py_len() function, it can be safely removed. (i is returned, len in not used)
(
chg int i, len=0; to int i;
chg for(i=0;self[i];i++) len=i; to for(i=0;self[i];i++);
suggest adding space after ; for readability, for(i=0; self[i]; i++);
)
Student report, cc4e/lectures/KR-1.pptx. My edit in (...).
With deep respect for Dr. Chuck. In reviewing the presentation, I found the following errors:
%s\\n
) is inserted in line 7 which breaks the '\n' operatorint i, len=0;
toint i;
chgfor(i=0;self[i];i++) len=i;
tofor(i=0;self[i];i++);
suggest adding space after ; for readability,for(i=0; self[i]; i++);
)