def VM(code):
A = 0
J = 0
types = [0]
tipsoint = 0
fypes = []
funsoint = 0
loop = [0,0]
Memorī = 0
funcs = [
lambda x: x + 1,
lambda x: x - 1,
lambda x: x * 2,
lambda x: x // 2,
]
while A < len(code):
if code[A] == "◇":
funsoint = (funsoint+1) % 4
elif code[A] == "□":
fypes.append(funcs[funsoint])
elif code[A] == "→":
tipsoint = (tipsoint+1) % len(types)
elif code[A] == "←":
tipsoint = (tipsoint-1) % len(types)
elif code[A] == "+":
types.append(0)
elif code[A] == "○":
for Q in range(len(fypes)):
types[tipsoint] = fypes[Q](types[tipsoint])
elif code[A] == "!":
print(chr(types[tipsoint]%96),end = "")
elif code[A] == "▲":
Memorī,types[tipsoint] = types[tipsoint],0
elif code[A] == "▼":
Memorī,types[tipsoint] = 0,Memorī
elif code[A] == "(":
loop.append([A, types[tipsoint]])
elif code[A] == ")":
if loop[-1][1] > 1:
A = loop[-1][0]
loop[-1][1] -= 1
else:
loop.pop()
elif code[A] == "×":
funsoint = 0
fypes = []
elif code[A] == "1":
print(types)
elif code[A] == "2":
print(funsoint)
elif code[A] == "3":
print(tipsoint)
A += 1
VM("""
×□○○○○○+++++
(×□→○○×◇◇□○×◇◇□○×◇◇□○□○▲
→▼×□○○○○○○○○!×◇□○○○○○○○○▲
→▼×□○○○○○!×◇□○○○○○▲
→▼×□○○○○○○○○○○○○!!×◇□○○○○○○○○○○○○▲
→▼×□○○○○○○○○○○○○○○○!×◇□○○○○○○○○○○○○○○○▲
→▼×◇◇◇□○!×◇◇□○▲
→▼×□○○○○○×◇◇□○○×□○○○!×◇□○○○×◇◇◇□○○×◇□○○○○○▲
→▼×□○○○○○○○○○○○○○○○!×◇□○○○○○○○○○○○○○○○▲
→▼×□○○○○○○○○○○○○○○○○○○!×◇□○○○○○○○○○○○○○○○○○○▲
→▼×□○○○○○○○○○○○○!×◇□○○○○○○○○○○○○▲
→▼×□○○○○!×◇□○○○○▲
→▼×◇◇◇□○×◇□○○×◇◇◇□○×◇□○○○○○!×□○○○○○×◇◇□○×□○○×◇◇□○▲
←→→)
""")
To embed this project on your website, copy the following code and paste it into your website's HTML: