Question: can you make this code without any error? So That I can the out show.... please I need it for the grade, please make it

can you make this code without any error? So That I can the out show.... please I need it for the grade, please make it without error. make it perfect

I used the software of pycharm.. After which the output can be done by the software of python... Thanks

can you make this code without any error? So That I can

the out show.... please I need it for the grade, please make

THIS IS THE CODE:

import numpy px_terms = int(input('Enter number of terms in px: ')) qx_terms = int(input('Enter number of terms in qx: ')) poly = {} for i in range(px_terms): ele = int(input('Enter coefficient {} for px: '.format(i + 1))) # if 'px' is not present already, add empty list with 'px' as key if 'px' not in poly: poly['px'] = [] # else, append input to the list else: poly['px'].append(ele) for i in range(qx_terms): ele = int(input('enter coefficient {} for qx: '.format(i + 1))) # if 'qx' is not present already, add empty list with 'qx' as key if 'qx' not in poly: poly['qx'] = [] # else, append input to the list else: poly['qx'].append(ele) option = input('Select Addition, Subtraction, Multiplication, Division: ') if option.lower() == "addition": print(numpy.polynomial.polynomial.polyadd(poly['px'], poly['qx'])) if option.lower() == "subtraction": print(numpy.polynomial.polynomial.polysub(poly['px'], poly['qx'])) if option.lower() == "multiplication": print(numpy.polynomial.polynomial.polymul(poly['px'], poly['qx'])) if option.lower() == "division": qu, re = numpy.polynomial.polynomial.polydiv(poly['px'], poly['qx']) print("Quotient: ", qu) print("Remainder: ", re)

VCS Window Help python Project - Composite Funtion 2.py Composite Funtion 2 Q0 to Composite Function.py X to Composite Funtion 2.py fo Area of paralelogrampy X 2 px_terms = int(input('Enter number of terms in px: )) 3 qx terms = int(input('Enter number of terms in qx: ')) 4 A5A 5 6 poly = 0 7 8 9 10 11 12 13 for i in range(px_terms): ale = int(input('Enter coefficient {} for px: ',format(i + 1))) # if 'px' is not present already, add empty list with 'px' as key if 'px' not in poly: poly['px'] = [] #alse, append input to the list else: e pozy['px').append(ele) 14 for i in range(qx_terms): ... 15 16 17 26 27 28 29 30 31 32 33 34 35 option = input('Select Addition, Subtraction, Multiplication, Division: ') if option. lower() == "addition": printlnumpy.polynomial.polynomial.polyadd(poly['px'], polyl'cx'])) if option. Lower() == "subtraction": print(numpy,polynomial.polynomial.polysub (poly['px'l polyl'cx'])) if option, lower() == "multiplication": print(numpy.polynomial.polynomial.polymul(poly['px'l, poly['cx'])) Cif option. Zower() == "division":... if aption lower() -- "addition - ok Terminal EventLog 30:14 CRLF UTF-8 4 spaces Python 3.10 (python Project) 2 Composite Funtion 2 AS AV Eile Edit View Navigate Code Defactor Run Tools Vs Window Help python Project - Composite Funtion 2.py python Project Composite Punti 2.py Project - - Composite Function.py X Composite Funtion 2 py Area of palalelogram.py X python Project Users\user\pycharm Projects\pythonPro 8 for i in range(px_terms): ven library TODI 9 ele = int(input('Enter coefficient {} for px: '.format(i + 1))) > Bilib 10 # if 'px' is not present already, add empty list with 'px' as key > Scots 11 1f 'px' not in poly: yitignore 12 poly('px'] = 0) pyverw.cfg 13 #else, append input to the list for Area of palalelogrampy 14 else: Combination of function.py 15 poly['px').append(ole) Io Composite Function.py 16 in Composite Funtion 2.py Create a program that cumiputes and displays a gaine 17 for i in range(ax_terms): ... Io Create a Python program that would accept and print 26 to main.py 27 > External Libraries 28 option = input('Select Addition, Subtraction, Multiplication, Division: ') 9 Scratches and Consoles 29 if option. lower() == "addition": 38 print(numpy.polynomial.polynonial.polyadd(poly['px'], poly['qx'])) 31 if option. Lower() == "subtraction": 32 print (numpy.polynomial.polynomial.polysub (poly('px'l polyl'qx'])) 33 If option. lower() == "ultiplication": 34 print (numpy.polynomial.polynomial.polynul(poly['px'l poly['qx'])) 35 Gif option, lower() == "division":... else fori in range(qx_terms] Problems Current File Project Errons fe Composite Funtion 2.py C:\Users\usen Pycharm Projects pythonProject 5 problems PEP : 0117 ever-indented:30 A PEP8E117 over indented 32 A PEP 8E117 over indented 34 A PEP 8 C117 over-indent:36 A PEP8: W292 no newline at end of file:38 Probicm Python Packages python Console Tamil Event Log 25:31 CIF UTF-8 4 spaces Python 2.10 (python Project 1

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!