It takes the shape of an I beam.
Answer:
- def splitTip(totalCost, numGuest):
- finalCost = totalCost * 0.15 + totalCost
- avgCost = finalCost / numGuest
- for i in range(numGuest):
- print("Guest " + str(i+1) + ": $" + str(round(avgCost,2)))
-
- splitTip(15.16,3)
Explanation:
The solution is written in Python 3.
To calculate the average cost shared by the guests, we create a function that takes two input, totalCost and numGuest (Line 1). Next apply the calculation formula to calculate the final cost after adding the 15% tips (Line 2). Next calculate the average cost shared by each guest by dividing the final cost by number of guest (Line 3). At last, use a for loop to print out the cost borne by each guest (Line 4-5).
There is only one programming language that is closest to a human language and is the most easy to learn other than HTML or CSS.
That language would be AppleScript. for both its simplicity and power, it has become an ideal language for basic Apple programmers to learn.
<span>All of the following are parts of the word processing window except for the button esc ____.</span>
Answer:
See explaination.
Explanation:
question is the root element which have two children one is M-C and other is Coding.
Again M-C have two sub children Points and parts
Note: The tree will be as shown in the attachment. kindly refer to attachment.
Here if we see the child of quiz(questions) at 0 position is number of type M-C and another child at location 1 is number of type Coding.
Now quiz.child(0) is number of type M-C which has two child and child at 0 is Points and child at 1 is Parts
quiz.child(0).child(1) is Points and now further points doesn't have any children hence going further to quiz.child(0).child(1).child(0) is nothing hence it will not return anything.
Next quiz.child(1) is number of type coding and value is 5.
Size of the tree is (2^depth)-1
and here depth of tree is 3 hence size is (2^3)-1 i.e. 7