brute forced prob 7 in linear time
added prob 9 through 11 instructions
added bit array (for fun?)