networking · beginner · ~15 min
Detect the terminating zero-chunk.
A chunk size of 0 marks the end of a chunked body. Implement int is_last_chunk(const char *hexsize) returning 1 if the hex size parses to 0, else 0.
#include <stdlib.h>
int is_last_chunk(const char *hexsize) {
/* TODO */
return 0;
}
Solve this exercise in the browser editor — compile and run against the test harness, no setup required.