In: Computer Science
You are an apple farmer who sell apples by the boxes. Each box contains 6 Apples. You have 30 boxes of apples. Price of each box is $20. Using cout object as studied in the class and by use of algorithm(s), display following in the format as written below:
1. Total number of apples in all boxes are ______________
2. Total apples will be sold for $_____________________
Upload your assignment here.
using python and no copy from other assingment and it has to be only pseduco
Answers are:
Pseudocode: in python
print('Total number of apples in all boxes are', num_of_boxes * num_of_apples_in_each_box)
print('Total apples will be sold for $', num_of_boxes * price_of_each_box)
========
CODE AND OUTPUT:
SOURCE CODE:
*Please follow the comments to better understand the code.
**Please look at the Screenshot below and use this code to copy-paste.
***The code in the below screenshot is neatly indented for better understanding.
# take tha variables to store the data num_of_boxes = 30 num_of_apples_in_each_box = 6 price_of_each_box = 20 # Answer to your 1st question print('Total number of apples in all boxes are', num_of_boxes * num_of_apples_in_each_box) # Answer to your 2nd question print('Total apples will be sold for $', num_of_boxes * price_of_each_box)
=====================