I have the code in python, as shown below:
import csv
fields = ['Output']
filename = 'data.csv'
MAX_DATA = 20
with open(filename, 'w', ) as csvfile:
csvwriter = csv.writer(csvfile, lineterminator = '\n')
csvwriter.writerow(fields)
for i in range (0, MAX_DATA):
action = '1000000000000000000000000000000000000000000000000000000000000001'
print (action) # Just used to see terminal line by line output
rows = [[action]]
csvwriter.writerows(rows)
The above works great, and using print (action)
I am able to see every action (the 64 bit string), being printed over and over again. Which is what I want/expect. I want to save the entire 64 bit string/int to csv, hence the csvwriter.
The problem I am running into is that when I open up the saved csv. My output in each row is 1E+63
, written in each row, up to MAX_DATA. It's being changed into scientific form.
I need that output in the csv file the entire 64 bit 'action' value, whether that action value is a string or a int doesn't matter.