Global variable Out and CreateOutFile() function

This commit is contained in:
JLo'w 2016-02-11 20:32:08 +01:00
parent 32278e7461
commit 4958ce6f7b
2 changed files with 8 additions and 0 deletions

View file

@ -37,6 +37,8 @@ Cp = []; # Positions of customers
Ci = []; # Needs of customers Ci = []; # Needs of customers
# {product number: qt} # {product number: qt}
Out = '' # Drones commands
# Debug # Debug
assert(len(Dp) == len(Di) == len(Dd) == len(Da) == D) assert(len(Dp) == len(Di) == len(Dd) == len(Da) == D)

6
out.py Normal file
View file

@ -0,0 +1,6 @@
#Out file
def CreateOutFile():
f = open(sys.argv[1], 'w')
f.write(len(Out)/10 + '\n' + Out)
f.close()