def dict_to_string(_dict):
 buffer = ''
 if (not isinstance(_dict, dict)):
  return _dict
 for key in _dict:
  value = _dict[key]
  if (not value):
   buffer += (str(key) + ' ')
  elif isinstance(value, list):
   for item in value:
    buffer += (((str(key) + '=') + str(item)) + ' ')
  else:
   buffer += (((str(key) + '=') + str(value)) + ' ')
 return buffer

def dict_to_string ( _dict ) : buffer = '' if ( not isinstance ( _dict , dict ) ) : return _dict for key in _dict : value = _dict [ key ] if ( not value ) : buffer += ( str ( key ) + ' ' ) elif isinstance ( value , list ) : for item in value : buffer += ( ( ( str ( key ) + '=' ) + str ( item ) ) + ' ' ) else : buffer += ( ( ( str ( key ) + '=' ) + str ( value ) ) + ' ' ) return buffer
convert a dictionary to a printable string .