Modified code and slides

Apologies for poor commit hygiene.