algorithm I did to impress my teacher | ScratchStats