finished code and started writing writeup