Question: 3. The class has a method. The method takes three parameters, (lab, midterm and final scores). The grade of the course is calculated with 20%

 3. The class has a method. The method takes three parameters,

3. The class has a method. The method takes three parameters, (lab, midterm and final scores). The grade of the course is calculated with 20% lab, 35% midterm and 45% final scores. The method returns the grade of the course. Write this class. 5. Write the code in python to open a file named "try.txt". 6- What will be displayed when the code is run? 4. What is printed by the following python code? arr = [[6, 2, 0, 11, 19,5, 6, 71] def func(x): k=0 try: if x = 0 raise "Zero division error" else: k= 6/ except: print('Error occurred") finally: if k == 0: k = 100 return k print(func (arr[0][2])) print(func (arr[1][2])) .X, y = 6,9 X, y = y, X def calc(c): if co7 return c else: return 1 print(calc(y),calc(x))

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!