I wanna loop the following scripts for 40 times ,then write it into a txt file.However, I am the begginning user of Python, no idea how to do that,
print ('TIME = 0.00 hours since 1999-06-30 14:00:00 +00:00')
print ('x_spw_eye = 138.50')
print ('y_spw_eye = 7.20')
print ('pdrop_spw_eye = 1000.00')
for i in range(1500):
print " ".join('%8.1f' % 0 for j in range(16))
print " ".join('%8.1f' % 0 for j in range(16))
print " ".join('%8.1f' % 0 for j in range(4))
and also should change the space number of the parameter 'x_spw_eye', 'y_spw_eye','pdrop_spw_eye',
For example,
in the next loops , the head should be like,
TIME = 6.00 hours since 1999-06-30 14:00:00 +00:00
x_spw_eye = 138.10
y_spw_eye = 12.50
pdrop_spw_eye = 985.00
Is there any idea what kind of clue should I follow with?
Thank you so much!!!
All the bests, Li