Skip to content

Instantly share code, notes, and snippets.

View adeyahya's full-sized avatar
😶
I can't fix broken printing machine!

Ade Yahya Prasetyo adeyahya

😶
I can't fix broken printing machine!
View GitHub Profile
@adeyahya
adeyahya / mysql-docker.sh
Created March 27, 2020 13:58 — forked from spalladino/mysql-docker.sh
Backup and restore a mysql database from a running Docker mysql container
# Backup
docker exec CONTAINER /usr/bin/mysqldump -u root --password=root DATABASE > backup.sql
# Restore
cat backup.sql | docker exec -i CONTAINER /usr/bin/mysql -u root --password=root DATABASE
/schemes:
edge_light: &edge_light
primary:
background: "0xfafafa"
foreground: "0x4b505b"
normal:
black: "0x4b505b"
red: "0xd05858"
green: "0x608e32"
const express = require("express");
const app = express();
const cache = [0, 3];
const getPi = (series = 0) => {
if (series === 0) return 3;
const middle = 4 * series;
const head = 4 / ((middle - 2) * (middle - 1) * middle);