Skip to content

Instantly share code, notes, and snippets.

View thepabloaguilar's full-sized avatar
🎯
Focusing

Pablo Aguilar thepabloaguilar

🎯
Focusing
View GitHub Profile
@programaker
programaker / monads-are-monoids-in-the-category-of-endofunctors.txt
Created November 3, 2018 02:57
Monads are Monoids in the Category of Endofunctors
"Monads are Monoids in the Category of Endofunctors"
If you are a functional programmer, you've probably heard this statement before.
To understand it, first we need to understand its component parts:
. Category
. Monoid
. Endofunctor
After this, we will glue those parts together piece by piece to grasp the whole.
@programaker
programaker / why-do-we-need-monads.scala
Last active August 13, 2021 04:19
Why do we need Monads?
//Functional programming is programming combining functions.
//
//We have a bunch of simple functions, then combine them into
//more and more complex functions until have a full program.
//
//The simplest case is when the functions are COMPOSABLE, for example, given the functions:
f: A => B
g: B => C
h: C => D

Oh my zsh.

Install with curl

sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"

Enabling Plugins (zsh-autosuggestions & zsh-syntax-highlighting)

  • Download zsh-autosuggestions by
@imwilsonxu
imwilsonxu / app.py
Last active September 14, 2024 12:55
[Flask + Wtforms + Select2] #flask
# -*- coding: utf-8 -*-
from flask import Flask, request, render_template, current_app
from flask_wtf import Form
from wtforms.validators import DataRequired
from wtforms import SelectField, SelectMultipleField, SubmitField
app = Flask(__name__)