Revert "try fileinput instead of stdin directly because I think it buffers..."

This reverts commit 9d418bab44ed265086269c9fd830f0e8e9bef81d.