Already have an account? Get multiple benefits of using own account!
Login in your account..!
Remember me
Don't have an account? Create your account in less than a minutes,
Forgot password? how can I recover my password now!
Enter right registered email to receive password!
''+msg+HTML_bottom # ---------------------- ReadData --------------------------------def readdata(): f=open(''restaurants.txt'',''r'') s=f.read() f.close() y=s.replace(''Reserve Now'','''') k=y.strip() l=k.split(''\n'') new=[] x=0 while x if len(lines) < 2: PrintError(''ERROR: Bad dataset in ''+ Restaurant_filename) return '''' elif: new+=[l[x].split(''\t'')] x+=1 return new lines = lines[1:] # ignore column headers return lines# ------------------------- CreateMasterList -------------------def CreateMasterList(lines): global MasterList for line in lines: d = {} fields = line.split('','') if len(fields) >= 6: if ''"'' in line: words = line.split(''"'') d[''name''] = words[1].strip() else: d[''name''] = fields[1].strip() if fields[0] == ''s'': d[''state'']=False else: d[''state'']=True d[''city'']=(fields[-3]) d[''cuisine'']=(fields[-1])]) MasterList.append(d)# ------------------------- PrintIndividual ---------------------def Printchecko(restaurant): lookfor = restaurant.strip().lower() sortlist=[] for d in MasterList: if lookfor in d[''name''].lower(): d=Highlightrestaurant(d,lookfor) sortlist.append([d[''name''].lower(),d]) sortlist.sort() header=''Restaurant with names containing "''+ restaurant+''"'' PrintTable(header,sortlist)# --------------------------- HighlightRestaurant-------------------def HighlightRestaurant (d,lookfor): front='''' back='''' mixed=d[''name''] low=mixed.lower() ln=len(lookfor) new_mixed='''' while lookfor in low: pos=low.find(lookfor) new_mixed=mixed[:pos]+front+mixed[pos:pos+ln]+back mixed=mixed[pos+ln:] low=low[pos+ln:] new_mixed+=mixed d[''name-HTML'']=new_mixed return d# ------------------------ PrintTable ----------------------------def PrintTable(header,sortedlist): s=HTML_head+HTML_top s+=''
APPLICATION PACKAGES : There are two options. You can either write your own program or buy an applications package, i.e. a proprietary program, 'off-the-shelf. The former option i
Write an ARM subroutine which will extract a substring from a string. You will need to use the library routine malloc to allocate memory for the new string. The subroutine signatu
#question.a tree has 0 off springs at each node. if it had a label L, what will be the maximum number of nodes that the tree can have. only an expression involving the number of no
Telecommunication Networks Architecture is the manner in which the components of thenetwork are organized and integrated to provide telecommunication services to users ofthe netwo
akrenda club has just opened their jym and pools services. They need a system that can keep record of total sales of each. The club has silver and gold members. The silver members
create a simple Visual Basic project
Question 1 List and explain the ways used to close an MS Word document Question 2 What is MS-Excel? List the steps involved in starting Microsoft Excel Question 3 What i
HARDWARE BASICS In the foregoing section of this Unit, an attempt has been made to explain to you the historic perspective relating to the development of computer from its ear
QUESTION (a) Outline the five main steps in the Web Design Process (b) Draw an annotated diagram explaining how data is transmitted to web servers during a standard form sub
Question 1 Write short notes on (a) Office Automatics System (b) Transaction Processing System Question 2 What is a too
Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!
whatsapp: +91-977-207-8620
Phone: +91-977-207-8620
Email: [email protected]
All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd