Skip to content

Instantly share code, notes, and snippets.

View Sillians's full-sized avatar
💭
AI | ML Hobbyist

Basil Ihuoma Sillians

💭
AI | ML Hobbyist
View GitHub Profile
@dmmeteo
dmmeteo / 1.srp.py
Last active May 8, 2024 10:27
SOLID Principles explained in Python with examples.
"""
Single Responsibility Principle
“…You had one job” — Loki to Skurge in Thor: Ragnarok
A class should have only one job.
If a class has more than one responsibility, it becomes coupled.
A change to one responsibility results to modification of the other responsibility.
"""
class Animal:
def __init__(self, name: str):
@ibraheem4
ibraheem4 / postgres-brew.md
Last active May 8, 2024 14:30 — forked from sgnl/postgres-brew.md
Installing Postgres via Brew (OSX)

Installing Postgres via Brew

Pre-Reqs

Brew Package Manager

In your command-line run the following commands:

  1. brew doctor
  2. brew update
@mariocj89
mariocj89 / python-logging.md
Last active April 13, 2024 13:15
Understanding logging in Python

Logging trees

Introduction

When applications are running in production, they become black boxes that need to be traced and monitored. One of the simplest, yet main, ways to do so is logging. Logging allows us - at the time we develop our software - to instruct the program to emit information while the system is running that will be useful for us and our sysadmins.