You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
defformat_unit(value, unit):
""" Formats the given value as a human readable string using the given units. :param float|int value: a numeric value :param str unit: the unit for the value (kg, m, etc.) :rtype: str """returnf"{value}{unit}"
We produce this
fromtypingimportUniondefformat_unit(value: Union[float, int], unit: str) ->str:
""" Formats the given value as a human readable string using the given units. :param value: a numeric value :param unit: the unit for the value (kg, m, etc.) """returnf"{value}{unit}"