def getFlagNames(flags):
 if (flags == 1):
  return 'PAYLOAD'
 elif (flags == 2):
  return 'NEW_TICKET'
 elif (flags == 4):
  return 'PRNG_SEED'
 else:
  return 'Undefined'

def getFlagNames ( flags ) : if ( flags == 1 ) : return 'PAYLOAD' elif ( flags == 2 ) : return 'NEW_TICKET' elif ( flags == 4 ) : return 'PRNG_SEED' else : return 'Undefined'
return the flag name encoded in the integer flags as string .