Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View EZLiang's full-sized avatar
🦆
having fun

EZLiang

🦆
having fun
View GitHub Profile
@EZLiang
EZLiang / regex.md
Last active January 21, 2022 14:30
Regex

Regex

is a very simple esoteric programming language.

The program is of the form

c/filter/flags/halt/flags2 comments

Note that /s in c must be escaped, and special chars in /filter/flags and /halt/flags2 must be escaped, as they are regular expressions and subject to their rules. Flags are case insensitive. Supported flags:

  • n - also consider non-printable characters (if on for any is automatically on for the other)
  • i - case-insensitive
@EZLiang
EZLiang / ezlife.md
Last active September 19, 2021 17:14
ezlife pattern collection

EZLife

A collection of sparkers not found (I think) in other collections

Credits

  • p4.rle: All Scorbie, except for the hw emulator whose stator has a mango, which is by Sokwe
  • p5.rle: Scorbie, except for the three-dot sparker partially by A for Awesome
  • p7.rle: Collected by Sokwe, credits can be found here: https://www.conwaylife.com/forums/viewtopic.php?f=2&t=1437&p=58533#p58533. The added pipsquirter is by Scorbie, and the other added sparker is by Extrementhusiast. Also, the big sparker is wwei

Notes

  • p4.rle: The emulator components can be mixed-and-matched, several samples shown
@EZLiang
EZLiang / obfuscate.py
Created March 6, 2021 01:27
Obfuscated Python code
NOTHING = lambda: None
def IF(condition, yes, no=NOTHING):
if condition:
return yes()
else:
return no()
def ITERATE(iterable, fun):
for i in iterable:
@EZLiang
EZLiang / tabulate.py
Last active March 3, 2021 14:23
Vote tabulator for POTY 2020
import re, json
names = ["Beehive push catalyst", "Natural loafers", "34-bit still life enumeration", "c/61 near-spaceship", "p9 heavyweight emulator", "p5 lightweight emulator/catalyst", "New c/5 diagonal spaceships", "New growing spaceships", "New longest 16x16 methuselah", "New c/10 orthgonal technology", "Better universal regulator", "19-bit still life syntheses", "c/5 and c/6 guns", "Cheaper universal construction", "Width-12 c/6 orthogonal spaceship", "New small Corderships", "p10 glider shuttle", "New agar technology", "Speed Demonoid", "LoM hasslers", "New c/6 diagonal pushalong", "New 2c/7 technology", "4×N block agar construction", "Rob's p16", "Loafer bitmap printer", "Cordercolumn", "Stable L122", "Stable barge-crosser", "Small c/5 diagonal puffer", "New grayship technology", "Glider syntheses from Glider_stdin", "New XWSS signal technology", "Silverfish", "Bandersnatch", "Spaceship eaters and spaceship-to-G converters", "Record-setting diehards", "Smaller 3c/7 spaceships", "p28 gun", "Spaceship
import discord
client = discord.Client()
@client.event
async def on_message(msg):
if msg.author == client.user:
return
elif client.user in msg.mentions:
@EZLiang
EZLiang / COVID-19.py
Created March 29, 2020 18:24
COVID-19 simulator
import numpy, scipy.integrate, matplotlib.pyplot
pop = 300000000.0
recovery = 0.2
badreco = 0.005
death = 0.001
contact = 0.3
sick = 30000.0
@EZLiang
EZLiang / gistrunner.py
Last active March 19, 2020 15:00
Gist Runner Python 3 -- run gists on your computer
"""
Copyright (c) 19 March 2020 EZLiang
This is distributed under the absolutely free lisence (https://gist.github.com/EZLiang/65b9a273fe2790d9abe31baf4f7b9d42)
To run:
----
$ python gistrunner.py username/gist_hash filename
or whichever python version works for you:
- python
- python3
@EZLiang
EZLiang / test_gist.py
Created March 19, 2020 00:48
test_gist
print("hello")
@EZLiang
EZLiang / LICENSE
Last active February 17, 2020 23:04
"Absolutely Free" lisence
ABSOLUTELY FREE LICENSE
The RIGHTS are hereby granted to all distributors and clients of this software under the TERMS AND CONDITIONS
TERMS AND CONDITIONS
1. The LICENSE must remain the same.
2. All future versions must be open source.
3. This software shall not be distributed for personal or corporate gain.
4. The source of this software must be provided.
@EZLiang
EZLiang / ns.ipynb
Last active March 23, 2022 19:25
Number Synthesizer Plus
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.