Skip to content

Instantly share code, notes, and snippets.

View Mando75's full-sized avatar
🤖
Meaningless [C]ode

Bryan Müller Mando75

🤖
Meaningless [C]ode
View GitHub Profile
@wesbos
wesbos / async-await.js
Created February 22, 2017 14:02
Simple Async/Await Example
// 🔥 Node 7.6 has async/await! Here is a quick run down on how async/await works
const axios = require('axios'); // promised based requests - like fetch()
function getCoffee() {
return new Promise(resolve => {
setTimeout(() => resolve('☕'), 2000); // it takes 2 seconds to make coffee
});
}
@jdelafon
jdelafon / hierholzer.py
Created June 29, 2016 11:45
Hierholzer's algorithm for Eulerian graphs
# Hierholzer's algorithm for Eulerian graphs #
"""
EXAMPLE
V = [1,2,3,4,5,6]
E = [(1,2),(2,3),(3,4),(4,5),(5,6),(6,1),(2,6),(6,4),(4,2)]
returns [1, 2, 6, 4, 2, 3, 4, 5, 6, 1]
V = ["AA","AB","BC","CD","DE","EF"]
E = [("AA","AB"),("AB","BC"),("BC","CD"),("CD","DE"),("DE","EF"),("EF","AA"),("AB","EF"),("EF","CD"),("CD","AB")]
@robphoenix
robphoenix / spacemacs-cheshe.md
Last active February 6, 2024 23:11
[DEPRECATED] Spacemacs Cheat Sheet - Visit https://github.com/Ben-PH/spacemacs-cheatsheet

This is unmaintained, please visit Ben-PH/spacemacs-cheatsheet

Useful Spacemacs commands

  • SPC q q - quit
  • SPC w / - split window vertically
  • SPC w - - split window horizontally
  • SPC 1 - switch to window 1
  • SPC 2 - switch to window 2
  • SPC w c - delete current window
@PurpleBooth
PurpleBooth / README-Template.md
Last active May 6, 2024 07:22
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites