#include "types.h" #include "stat.h" #include "user.h" char buf[512]; void wc(int fd, char *name) { int i, n; int l, w, c, inword; l = w = c = 0; inword = 0; while((n = read(fd, buf, sizeof(buf))) > 0){ for(i=0; i