Initial code after transcribe
Tweaks here and there
Refactor to remove breaks
Laying out the purpose of functions