import math

# size in mm
mill = 0.8
circ = 2.54 
zmax = -22
step = 5

r = (circ-mill)/2

def hole(xpos,ypos):
    print ('G00 Z5.0')
    print ('G00 X{0:.4f} Y{1:.4f}' .format( xpos, ypos + r))

    for z in range (-2, zmax, -2):
        print ('G01 F50')
        print ('G01 Z{0:.4f}' .format(z/10))
        print ('G01 X{0:.4f} Y{1:.4f}' .format( xpos, ypos + r))
        for i in range (0,360,step*3):
            print ('G01 X{0:.4f} Y{1:.4f}' .format(xpos + r * math.sin(math.radians(i)) , ypos + r * math.cos(math.radians(i))))
        print ('G01 X{0:.4f} Y{1:.4f}' .format( xpos, ypos + r))
                
    print ('G00 Z5.0')


hole(4.92125, 8.73125)
hole(72.39, 8.73125)
hole(148.93925, 8.73125)
hole(14.2875, 40.48125)
hole(88.10625, 40.48125)
hole(145.25625, 40.48125)
hole(4.92125, 78.58125)
hole(73.81875, 78.58125 )
hole(130.96875, 78.58125)
hole(40.814625, 109.22)
hole(119.97175, 109.22)
