RosettaCodeData/Task/Map-range/PARI-GP/map-range.parigp

2 lines
57 B
Text
Raw Permalink Normal View History

2023-07-01 11:58:00 -04:00
map(r1,r2,x)=r2[1]+(x-r1[1])*(r2[2]-r2[1])/(r1[2]-r1[1])