a) change printwriter to outputstream.write
b) fix the checker bug. (run the checker as a thread)