def python_version_string(version=None):
 (major, minor, micro, release_level, serial) = split_python_version(version)
 s = ('%d.%d' % (major, minor))
 if (micro > 0):
  s += ('.%d' % micro)
 if (release_level != 'final'):
  s += release_level[0]
  s += ('%s' % serial)
 return s

def python_version_string ( version = None ) : ( major , minor , micro , release_level , serial ) = split_python_version ( version ) s = ( '%d.%d' % ( major , minor ) ) if ( micro > 0 ) : s += ( '.%d' % micro ) if ( release_level != 'final' ) : s += release_level [ 0 ] s += ( '%s' % serial ) return s
convert a numeric python version to a printable string .