code: def compliment(rest):
  	
  	compurl = 'http://www.madsci.org/cgi-bin/cgiwrap/~lynn/jardin/SCG'
  	comphtml = ''.join([i.decode() for i in urllib.request.urlopen(compurl)])
  	compmark1 = '<h2>\n\n'
  	compmark2 = '\n</h2>'
  	compliment = comphtml[
  		comphtml.find(compmark1) + len(compmark1):comphtml.find(compmark2)]
  	if compliment:
  		compliment = re.compile(r'\n').sub('%s' % ' ', compliment)
  		compliment = re.compile(r'  ').sub('%s' % ' ', compliment)
  		if rest:
  			complimentee = rest.strip()
  			karma.Karma.store.change(complimentee, 1)
  			compliment = re.compile(r'\b(your)\b', re.IGNORECASE).sub(
  				'%s\'s' % complimentee, compliment)
  			compliment = re.compile(r'\b(you are)\b', re.IGNORECASE).sub(
  				'%s is' % complimentee, compliment)
  			compliment = re.compile(r'\b(you have)\b', re.IGNORECASE).sub(
  				'%s has' % complimentee, compliment)
  		return compliment
docs: Generate a random compliment from
  	http://www.madsci.org/cgi-bin/cgiwrap/~lynn/jardin/SCG