web data known as jsonwhich stands for javascript object notation for exampleif we read just the first line of file you may see something like in [ ]path 'ch /usagov_bitly_data- txtin [ ]open(pathreadline(out[ ]'" ""mozilla\\/ (windows nt wow applewebkit\\/ (khtmllike geckochrome\\ safari\\/ "" ""us""nk" "tz""america\\/new_york""gr""ma"" "" qovh"" ""wflqtf"" ""orofrog""al""en-us,en; = ""hh"" usa gov"" ""http:\\/\\/www facebook com\\/ \\/ aqefzjsi\\/ usa gov\\/wflqtf"" ""http:\\/\\/www ncbi nlm nih gov\\/pubmed\\/ "" " "hc" "cy""danvers""ll" - }\npython has numerous built-in and rd party modules for converting json string into python dictionary object here 'll use the json module and its loads function invoked on each line in the sample file downloadedimport json path 'ch /usagov_bitly_data- txtrecords [json loads(linefor line in open(path)if you've never programmed in python beforethe last expression here is called list comprehensionwhich is concise way of applying an operation (like json loadsto collection of strings or other objects convenientlyiterating over an open file handle gives you sequence of its lines the resulting object records is now list of python dictsin [ ]records[ out[ ]{ ' ' 'mozilla/ (windows nt wow applewebkit/ (khtmllike geckochrome safari/ ' 'al' 'en-us,en; = ' ' ' 'us' 'cy' 'danvers' ' ' ' qovh' 'gr' 'ma' ' ' 'wflqtf' 'hc' 'hh' ' usa gov' ' ' 'orofrog' 'll'[ - ] 'nk' ' ' ' ' ' 'tz' 'america/new_york' ' ' ' introductory examples www it-ebooks info