Code for working with 0-Hecke algebras