freq = {} x=[] while gets() for word in $_.split('/\s/') a=word.split(" ") end printf("%d %d %d\n",a[0],a[1],a[2]) end