Skip to content

Instantly share code, notes, and snippets.

View kemiabdulrahman's full-sized avatar

Abdulrahman Mafe kemiabdulrahman

View GitHub Profile
@bradtraversy
bradtraversy / typescript-crash.ts
Last active March 18, 2026 12:13
Basic intro to TypeScript (From YouTube Crash Course)
// Basic Types
let id: number = 5
let company: string = 'Traversy Media'
let isPublished: boolean = true
let x: any = 'Hello'
let ids: number[] = [1, 2, 3, 4, 5]
let arr: any[] = [1, true, 'Hello']
// Tuple
@mkx775
mkx775 / 2_Web_Scraping_From_W3Schools.py
Created August 17, 2020 03:46
Web scraping from w3schools - A gist by @mkx775
# Web scraping from w3schools
from urllib.request import urlopen as get
from bs4 import BeautifulSoup
b_url = 'https://www.w3schools.com/python/'
n_url, s_url = 'python_intro.asp', 'python_exam.asp'
page_count = 0
def start(base_url, next_url, stop_url):

MongoDB Cheat Sheet

Show All Databases

show dbs

Show Current Database

@bradtraversy
bradtraversy / js_linked_list.js
Last active July 20, 2025 19:42
JS Linked List Class
// Construct Single Node
class Node {
constructor(data, next = null) {
this.data = data;
this.next = next;
}
}
// Create/Get/Remove Nodes From Linked List
class LinkedList {
@bradtraversy
bradtraversy / mysql_cheat_sheet.md
Last active March 17, 2026 17:32
MySQL Cheat Sheet

MySQL Cheat Sheet

Help with SQL commands to interact with a MySQL database

MySQL Locations

  • Mac /usr/local/mysql/bin
  • Windows /Program Files/MySQL/MySQL version/bin
  • Xampp /xampp/mysql/bin

Add mysql to your PATH

@tomayac
tomayac / #intro.md
Last active December 18, 2022 07:22
Snippet repository

There are many code snippets which can be quickly used to show/demo stuff in Chrome for demos or pitches, or just debugging, QA and testing. This is a collection of such snippets with some instructions Snippets can be saved to Chrome and run via one click again!

How to use snippets in Chrome

  • Open Command Menu in DevTools
  • Apple-Shift-P
  • Pick "Create new snippet"