works with floats