#include void IOStream::print(char* str) { if (term == 0) return; term->print(str); } void IOStream::printf(char* fmt, ...) { if (term == 0) return; va_list ap; va_start(ap, fmt); term->vprintf(fmt, ap); va_end(ap); } char* IOStream::readln() { if (term == 0) return 0; return term->readln(); }