def convert(num):
    """
    This function convert number
    :param num: input numger
    :type num:int
    :return: output string
    """
    for x in ['wh', 'Kwh', 'Mwh', 'Gwh']:
        if num < 1000:
            return '%3.1f %s' % (num, x)
        num /= 1000
