Sort by Length for OCaml Golf Competition by shinh

b[9999],*p;c(a,b){p=strlen(a)-strlen(b)?:strcmp(a,b);}main(){for(p=b;gets(p);p+=9);qsort(b,(p-b)/9,36,c);for(p=b;*p;p+=9)puts(p);}

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page