fixed some loops

fixed some loops in da code, like turning while(n) into for(;n;n—),
thinking it’ll help compilers (and not knowing). Also took out some
branching tests, not sure what I’m doing there either