Skip to content

Instantly share code, notes, and snippets.

View Stilic's full-sized avatar

Stilic

View GitHub Profile
@Stilic
Stilic / brainfuck.py
Last active December 22, 2023 13:59
Minimal interpreter for Brainfuck, written in Python. Doesn't make use of any AST, parses and interprets the code at the same time.
code = "++++++++[>++++[>++>+++>+++>+<<<<-]>+>+>->>+[<]<-]>>.>---.+++++++..+++.>>.<-.<.+++.------.--------.>>+.>++."
position = 0
memory = {}
pointer = 0
def getPointerValue():
try:
return memory[pointer]
except:
@Stilic
Stilic / install_soulles_dx.bat
Last active August 4, 2023 19:10
A few BATs (command line executable files) to help you install and update Soulles DX!! Drop these files into the mods folder of your Yoshi Engine copy. You need to have Git installed before using these scripts!
git clone https://github.com/GrayAnimates/Soulles-DX.git
@Stilic
Stilic / how-to-fix-polymod.md
Last active September 22, 2022 08:05
NEVER use a older version of Polymod (like 1.3.0)! Just use this simple tutorial!

Run this in a terminal:

haxelib remove hscript
haxelib install hscript

And put this in the Project.xml, below the Haxedefines category:

<!--Enable HScript fine error reporting at parsing time-->
import os
import random
def run(command):
return os.popen(command).read()
def clear():
if os.name == "nt":
@Stilic
Stilic / README.txt
Last active April 26, 2021 10:56
"Pro type" RSS reader
Rich Reader
===========
"Pro type" RSS reader GUI writtent in Python 3 with Feedparser and GUIzero.
Install for first launch
------------------------
For launch it, just type in a terminal `pip3 install --upgrade feedparser guizero || python3 RichReader.py`.
@Stilic
Stilic / firstnumber.py
Created December 8, 2020 18:48
a python 3 program for say if thats number is a first number
# define the basic variable
stop = False
# make an function for gets all factors of an number
def getFactors(n):
# create an empty list for factors
factors=[];
# loop over all factors
for i in range(1, n + 1):