Question: p please write a code for Java. with using 'if else'. thank you Write a program that asks for the weight of a package in
p please write a code for Java. with using 'if else'. thank you
Write a program that asks for the weight of a package in pounds determines the number of boxes needed to pack the items. Assume that a box can hold a maximum of 3 pounds. For now, assume that the package weight is an integer. Here is 2 sample executions: green font is the user input We package 3 pounds in a box. Tell me how many pounds do you have, and I will tell you how many boxes you need Enter the total weight in pounds: 17 You need 6 Boxes Use named constants, do NOT use literals! We package 3 pounds in a box. Tell me how many pounds do you have, and I will tell you how many boxes you need Enter the total weight in pounds: 0 You need 1 Boxes 39
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
