%e should work like in printf in C, it should format a floating-point number using scientific notation.