1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
GREYUIT [131]
2 years ago
5

Write a python program that takes two lists as input from the user, multiplies the index wise elements of the two lists and adds

it to a new variable. While doing the program you should handle the following exceptions: Return an exception if an element in a list is not a number stating “The list has some non number values”. Return an exception if there is an index out of bound stating “Index out of bound”. ============================= Example 1: Input: list_one = [1, a, 2, 4] list_two =[5, 6, 7, 8] Output: The list has some non number values
Computers and Technology
1 answer:
nevsk [136]2 years ago
3 0

Answer:

list_one=[]

list_two=[]

list_three=[]

str1=input("list_one:")

for i in str1:

   if i.isdigit():

       i=int(i)

       list_one.append(i)

   elif i.isalpha():

       list_one.append(i)

str2=input("list_two:")

for i in str2:

   if i.isdigit():

       i=int(i)

       list_two.append(i)

   elif i.isalpha():

       list_two.append(i)

print(list_one)

print(list_two)

if len(list_one)==len(list_two):

   for i in range(len(list_one)):

       multiply=list_one[i]*list_two[i]

       add=str(multiply)

       list_three.append(add)

else:

   print("Index out of bound")

n=0

for i in list_three:

   if i.isdigit():

           n+=1

   else:

       print("The list has some non number values")

print(list_three)

You might be interested in
Which of the following refers to a collection of colors, fonts, and effects that can be
aev [14]

Answer:

c)style set

Explanation:

It changes the appearance of a document

4 0
2 years ago
As a technical support rep, michael is responding to a customer's question sent to him via e-mail. what should michael's first t
hoa [83]

As a technical support rep, Michael's first task will be option b: Determine the purpose of the message he will send as a response.

<h3>Who is a technical support rep?</h3>

The role or duty of a Technical Support is known to be any person that tends to troubleshoot customer tech issues.

Note that they are said to be people who often resolve issues that are linked to computers, phones, tablets, and others.

Therefore, As a technical support rep, Michael's first task will be option b: Determine the purpose of the message he will send as a response.

Learn more about technical support  from

brainly.com/question/27366294
#SPJ1

See option

a. conduct any necessary research

b. determine the purpose of the message he will send as a response

c. Hit the "reply" button

d. start composing his reply

7 0
1 year ago
What are the raw materials for the process of photosynthesis​
Ray Of Light [21]
The raw materials of photosynthesis, water and carbon dioxide, enter the cells of the leaf, and the products of photosynthesis, sugar and oxygen, leave the leaf.
7 0
3 years ago
Read 2 more answers
Which website can help you find antivirus software ?
sergey [27]

If you have windows you have Windows Defender Installed already!!

5 0
3 years ago
Give five example of a dedicated device ​
kogti [31]

Common examples are ATMs, POS terminals, and airport ticket vending machines. Cashierless checkout technologies like “Scan and Go,” inventory scanning, corporate-owned work profile devices, self-ordering kiosks, mobile devices, and POS/m POS are some of the most common examples of dedicated devices in use today.

6 0
2 years ago
Read 2 more answers
Other questions:
  • What exactly is a byte? A byte is a term that is short for binary digit. 8 bytes hold about one letter, one number, or one speci
    10·1 answer
  • Differentiate between third and fourth generation of computer​
    6·1 answer
  • What is the name of a popular high-level computer programming and scripting language that is the name of a snake?
    10·1 answer
  • Find the Nearest Repeated Entries in an Array People do not like reading text in which a word is used multiple times in a short
    15·1 answer
  • What does cmyk stand for?
    5·2 answers
  • Lets say if my computer shut down every 10 minutes. What can you do to solve the problem. Hint: Use these word in you answer: ha
    10·2 answers
  • Which model represents any process in general?
    6·1 answer
  • What does the following loop do? val = 0 total = 0 while (val &lt; 10): val = val + 1 total = total + val print(total)
    15·1 answer
  • Simple Java programming
    15·2 answers
  • ASAP 50 POINTS
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!