def generateTinyURL(URL):
 target = ('http://tinyurl.com/api-create.php?url=' + URL)
 response = urllib2.urlopen(target)
 return response.read()

def generateTinyURL ( URL ) : target = ( 'http://tinyurl.com/api-create.php?url=' + URL ) response = urllib2 . urlopen ( target ) return response . read ( )
generates a compressed url .