• dream_weasel@sh.itjust.works
    link
    fedilink
    arrow-up
    4
    ·
    edit-2
    1 day ago

    Minor simplification: this works even without taking absolute value first of you use fix instead of floor.

    Edit: I don’t know if fix is in the stock math library on second thought…