Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import sys
- import os
- #import keras
- #x = int(sys.argv[1])
- #y = int(sys.argv[2])
- def getDataFile():
- print("Im getting data")
- exists = os.path.isfile('toPython.txt')
- while not exists:
- #Nothing happens here, im just waiting for the file to exist
- sick = "hej"
- f = open("toPython.txt", "r")
- i = 0
- f1 = f.readlines()
- for x in f1:
- i += 1
- f.close()
- os.remove("toPython.txt")
- return i
- def makeChoiceFile(i):
- f = open("toCs.txt","w+")
- f.write(str(i))
- f.close()
- numberOfLines = getDataFile()
- makeChoiceFile(numberOfLines)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement