Question: Write a shell (text-based) program, called multiply_stuff.py, that opens a text file called stuff.txt with 3 numbers per line separated by commas. For each line

Write a shell (text-based) program, called multiply_stuff.py, that opens a text file called stuff.txt with 3 numbers per line separated by commas. For each line in the text file, the program should print out the result of multiplying the first and third numbers.

For example, if stuff.txt has the following lines:

500,55,2

300,45,3

200,7,10

Then the following example output would happen.

PS C:\Users\ssiva\Desktop> python multiply_stuff.py

1000

900

2000

PS C:\Users\ssiva\Desktop>

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!