Data commit

This commit is contained in:
Ingy döt Net 2023-07-01 11:58:00 -04:00
parent 7387c8f97b
commit cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions

View file

@ -0,0 +1,41 @@
N =10
dim x( N), y( N)
firstPt =0
secondPt =0
for i =1 to N
read f: x( i) =f
read f: y( i) =f
next i
minDistance =1E6
for i =1 to N -1
for j =i +1 to N
dxSq =( x( i) -x( j))^2
dySq =( y( i) -y( j))^2
D =abs( ( dxSq +dySq)^0.5)
if D <minDistance then
minDistance =D
firstPt =i
secondPt =j
end if
next j
next i
print "Distance ="; minDistance; " between ( "; x( firstPt); ", "; y( firstPt); ") and ( "; x( secondPt); ", "; y( secondPt); ")"
end
data 0.654682, 0.925557
data 0.409382, 0.619391
data 0.891663, 0.888594
data 0.716629, 0.996200
data 0.477721, 0.946355
data 0.925092, 0.818220
data 0.624291, 0.142924
data 0.211332, 0.221507
data 0.293786, 0.691701
data 0.839186, 0.72826