PowerPoint Presentation
Assignment 1 (Due Jan 30)
CSCI 1226 Introduction to Computing Science and Programming
Description
This assignment explores:
Program sections like introduction, input, processing and output.
Use of integer division (/) to get whole number results.
Use of the modulus operator (%) to get whole number remainders.
Use of the (if – else if – else) statement to react accordingly.
Sample Run 1
This program is a tool to explore the
relationship between an area intended for
offices, the panels used to create smaller
spaces, and the circulation that results.
Enter the length of the room (feet): 20
Enter the depth of the room (feet): 25
Enter the length of a panel (feet): 8
The area of usable office space that can be separated by 8 foot panels is:
2 panels along the length times
3 panels along the depth
for a total of 384 square feet.
NOTE: The minimum allowable circulation-only space is 4 feet wide.
A circulation-only space can be made into the depth of the room.
Sample Run 2
This program is a tool to explore the
relationship between an area intended for
offices, the panels used to create smaller
spaces, and the circulation that results.
Enter the length of the room (feet): 25
Enter the depth of the room (feet): 20
Enter the length of a panel (feet): 8
The area of usable office space that can be separated by 8 foot panels is:
3 panels along the length times
2 panels along the depth
for a total of 384 square feet.
NOTE: The minimum allowable circulation-only space is 4 feet wide.
A circulation-only space can be made along the length of the room.
Sample Run 3
This program is a tool to explore the
relationship between an area intended for
offices, the panels used to create smaller
spaces, and the circulation that results.
Enter the length of the room (feet): 20
Enter the depth of the room (feet): 20
Enter the length of a panel (feet): 8
The area of usable office space that can be separated by 8 foot panels is:
2 panels along the length times
2 panels along the depth
for a total of 256 square feet.
NOTE: The minimum allowable circulation-only space is 4 feet wide.
Circulation-only spaces can be made along the length and depth of the room.
Sample Run 4
This program is a tool to explore the
relationship between an area intended for
offices, the panels used to create smaller
spaces, and the circulation that results.
Enter the length of the room (feet): 25
Enter the depth of the room (feet): 25
Enter the length of a panel (feet): 8
The area of usable office space that can be separated by 8 foot panels is:
3 panels along the length times
3 panels along the depth
for a total of 576 square feet.
NOTE: The minimum allowable circulation-only space is 4 feet wide.
There is no circulation-only space available.
Calculations
In the first sample run, 2 panels along the length fit, because 20 / 8 = 2. 3 panels along the depth fit, because 25 / 8 = 3. 384 square feet of space can be formed using panels, because (2 * 8) * (3 * 8) = 384.
And circulation-only space is available going into the depth of the space, because 20 % 8 = 4. And 4 >= the minimum allowable corridor width. Circulation-only space is not available along the length. Why?
Grading
Submit your file named “Area.java” to the Dropbox in BrightSpace called A1.
Out of 20 points:
8 points for documentation (include Javadoc)
8 points for correctly functioning code
4 points for EXACTLY matching output, compared to what’s depicted in these slides.
/docProps/thumbnail.jpeg