Answered step by step
Verified Expert Solution
Question
1 Approved Answer
def gcditer (a,b) : while if : else: b= return Q.5) (25) What is the outputt of the following script? Write vouneinswer inside the boxes.
def gcditer (a,b) : while if : else: b= return Q.5) (25) What is the outputt of the following script? Write vouneinswer inside the boxes. def sun(n) : for i in range(,n): for j in range (,1+1) : print (fun(i,j), end =) print() deffun(n,k):res=1ifk>nk:k=nkforiinrange(,k):res=res+(ni)res=resl/(i+1) return res sun(5) Q.4) (20) What is the output of the following script? Write vour answer inside the boxes. COMPUTER PHOOMAMMINEI Finat Exam Import re withopen("a.txt",mode="rt")asfile1:withopen("b.txt",mode="wt")asfile2:forlinein ifnotre.match(file2. Q.3) (15) What is the output of the following script? Write vour answer inside the boxes: import math def run(): try: x=/ print (x) return math. nan except Exception as e: print(e) return 2 finally: print("Catch me if you can!") return 3 print(run())
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started