python read input from stdin. print output to stdout