Did a non-looping mathematical solution