oh k, missed the mid(1) in the next line, seemed like the function was asymmetric, my bad!