subject
Computers and Technology, 01.11.2020 23:20 nae467

Code Problem 4 in Python 2. Problem 4

You’ve been hired to write a Python program for scanned items at a grocery mart. The scan is of the form [x, y, z] where x is the number of items purchased, y is the price of the item, and z is whether the item is taxable (7% tax on grocery items). For example assume you were given the list below:
[[1, 1.45, 1], [3, 4.24, 1], [2, 14.00, 0], [4, 1.25, 1]]
This means the amount owed is:
amt = 1(1.45) (1.07) + 3(4.24) (1.07) +2(14.00) + 4(1.25) (1.07)
= ((1.45 + 12.72 + 5.00)1.07) + 28.00
= 19.17(1.07) + 28.00
= 20.51 + 28.00
= 48.51

Code the problem in Python 2 and add “comments explaining what the code is doing.


Code Problem 4 in Python 2.

Problem 4
You’ve been hired to write a Python program for scanned ite

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 23:00
In which part of a professional email should you try to be brief, but highly descriptive?
Answers: 1
question
Computers and Technology, 22.06.2019 23:50
You need to design a circuit that implements the functions in the following table: s0 s1 function0 0 a + 10 1 a – b1 0 a + b1 1 a – 1s0 and s1 are 1-bit control inputs to select the function of the circuit. inputs a and b are 4-bitnumbers in 2s complement form. the output is also a 4-bit number in 2s complement form.you are allowed to use only one ttl 7483 4-bit adder to implement all the functions. but anynumber of other components (except the adder) can be used.hint: design a combinational logic circuit to modify the input b and the “carry input” of theadder depending on the control inputs s0 and s1.important: lab grade will depend on the working of the circuit & will be checked of by your labinstructor.1. is the output valid for the following input combinations: a. s0 = 0, s1 = 0, a = 7, b = 3? b. s0 = 0, s1 = 1, a = 7, b = 3? c. s0 = 1, s1 = 0, a = -4, b = -5? d. s0 = 1, s1 = 1, a = -8, b = 6? 2. what is the range of inputs (for both a and b) that will produce the valid output for all the functions?
Answers: 3
question
Computers and Technology, 23.06.2019 21:30
Enzo’s balance sheet for the month of july is shown. enzo’s balance sheet (july 2013) assets liabilities cash $600 credit card $4,000 investments $500 student loan $2,500 house $120,000 mortgage $80,000 car $6,000 car loan $2,000 total $127,100 total $88,500 which expression finds enzo’s net worth?
Answers: 1
question
Computers and Technology, 25.06.2019 05:30
When a game allows you to pick party members from a large pool, each with different classes and roles but in which no single party combination is clearly superior to others, the game is using: intransitive relationships transitive relationships orthogonal relationships parallel relationships
Answers: 1
You know the right answer?
Code Problem 4 in Python 2. Problem 4

You’ve been hired to write a Python program for s...
Questions
question
Mathematics, 20.10.2020 20:01
question
Mathematics, 20.10.2020 20:01
question
Mathematics, 20.10.2020 20:01
Questions on the website: 13722360