Skip to content

Instantly share code, notes, and snippets.

View CaedenPH's full-sized avatar

Caeden Perelli-Harris CaedenPH

View GitHub Profile
@CaedenPH
CaedenPH / README.md
Created December 3, 2022 21:07
Esoteric programming aproach

What is esoteric?

The definition in the oxford dictionary is:

adjective: esoteric

intended for or likely to be understood by only a small number of people with a specialized knowledge or interest.

"esoteric philosophical debates"

In other words, esoteric is doing something with the intent of confusing others.

@CaedenPH
CaedenPH / main.py
Created December 3, 2022 15:55
Using recursion to get the nodes of a binary tree
"""
Generates an `Iterator` object in order to perform the `max`
python builtin on the tree.
O(n) time complexity - Recurses through :meth:`depth_first_search`
with each element.
O(n) space complexity - At any point in time maximum number of stack
frames that could be in memory is `n`
"""
@CaedenPH
CaedenPH / sudoku.py
Created December 2, 2022 23:12
Generating a sudoku puzzle algorithm
from random import choice, randint
from utils import SudokuUtils
class SudokuGenerator(SudokuUtils):
"""
Represents the generator class to create, solve
and generate soduku boards.
"""
@CaedenPH
CaedenPH / README.md
Last active October 28, 2022 16:48
Script to make a systemd unit and host it on nginx from project (linux)

Usage

Prequisites

  1. Python 3.10 and above is required
sudo apt-get install python3
  1. Nginx must be installed
sudo apt-get install nginx