implement guess
add file input/output processing