Dateien hochladen nach „compiler“

main
Justus Jan Nico Wolff 2023-01-07 22:33:18 +01:00
parent ed63b1e75b
commit 403dcdad13
2 changed files with 20 additions and 0 deletions

View File

@ -0,0 +1,16 @@
import ast
code = open("compiler/target.py", 'r')
code = code.read()
name = input("name: ")
type = int(input("typ: "))
args = int(input("args amount: "))
out = {type: {"name": name, "code": code, "args": args}}
combinations = open("combinations.txt", 'r')
combinations = combinations.read()
combinations = ast.literal_eval(combinations)
for i in out:
combinations[i] = out[i]
file = open("combinations.txt", 'w')
file.write(str(combinations))
file.close()
print(out)

View File

@ -0,0 +1,4 @@
#executor
#block
#args
print(int(args[0])+int(args[1]))