Sort:  

Thanks for reading my work! Feel free to point out which parts you found unclear and I'll explain my logic in greater depth.