fork download
  1. $3{for(y=0;(x=(y*$2+1)/$3)%1>0;)y--;print $1+x,$1+y}
Success #stdin #stdout 0s 5312KB
stdin
5
1 1 1
5 2 5
5 3 2
50 48 49
6 0 1
stdout
2 1
4.8 4
4 4
49.0408 49
7 6