Free Essay

Cmis102 Homework Assignment 1

In: Computers and Technology

Submitted By ortoch
Words 495
Pages 2
CMIS102 Homework Assignment 1 (Worth 13% of your grade)

Problem definition: Calculate the usable area in square feet of house. Assume that the house has a maximum of four rooms, and that each room is rectangular.

A. Problem Analysis – Following the directions in the assignment, clearly write up your problem analysis in this section.

You need to determine the area of 4 rooms added together so you will need to allow the user to input both length and width for 4 separate rooms. You will then need to write code to multiply the length and width of each room separately and then add all four together. All variables will need to be float in anticipation of fractions of feet.

length1 = first room length

width1 = first room width

area1 = area of first room

length2 = second room length

width2 = second room width

area2 = area of second room

length3 = third room length

width3 = third room width

area3 = area of third room

length4 = fourth room length

width4 = fourth room width

area4 = area of fourth room

totalarea = final output variable for total square feet of home

B. Program Design – Following the directions in the assignment, clearly write up your problem design in this section and comment your pseudocode.

Main

Write "What is the room one's length in feet?"

Declare length1 As Float

Input length1

Write "What is the room one's width in feet?"

Declare width1 As Float

Input width1

Declare area1 As Float

Set area1 = width1 * length1

Write "What is the room two's length in feet?"

Declare length2 As Float

Input length2

Write "What is the room two's width in feet?"

Declare width2 As Float

Input width2

Declare area2 As Float

Set area2 = width2 * length2

Write "What is the room three's length in feet?"

Declare length3 As Float

Input length3

Write "What is the room three's width in feet?"

Declare width3 As Float

Input width3

Declare area3 As Float

Set area3 = width3 * length3

Write "What is the room four's length in feet?"

Declare length4 As Float

Input length4

Write "What is the room four's width in feet?"

Declare width4 As Float

Input width4

Declare area4 As Float

Set area4 = width4 * length4

Declare totalarea As Float

totalarea = area1 + area2 + area3 + area4

Write "The total square feet of the home is"

Write totalarea.

End Main

C. Program Comments and Test Data – Following the directions in the assignment, include your test data and expected results in this section.

Table 1. Include your test data table here

|Input: Room length and width (in feet) |Expected output: Total square footage of house (in |
| |square feet) |
|Room1: length=10, width=14; |374 |
|Room 2: length=9, width=10; | |
|Room 3: length=12, width=12; | |
|Room1: length=12, width=14; |268 |
|Room 2: length=10, width=10; | |
|Room1: length=8, width=10; |388 |
|Room 2: length= 10, width=8; | |
|Room 3: length=12, width=12; | |
|Room 4: length= 7, width=12; | |

The program works as expected with the above calculations as far as I can tell.

Similar Documents

Free Essay

Hooba

...CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102 Homework Assignment 1 (Worth 13% of your grade)CMIS102......

Words: 901 - Pages: 4

Free Essay

Calculating Sq Footage of a Room

...CMIS102 Homework Assignment 1 (Worth 13% of your grade) Student Name: Jacklyn Smith Class/Section: CMIS102 / Section 7986 Professor Name: Clarence Huff Assignment due date: 03Nov2013 Problem definition: Calculate the usable area in square feet of house. Assume that the house has a maximum of four rooms, and that each room is rectangular. A. Problem Analysis – Following the directions in the assignment, clearly write up your problem analysis in this section. |Input |Processing |Output |roomWidth |Read roomWidth |totalArea |roomLength |Read roomLength | |Calculate area | |Calculate totalArea | |Display totalArea B. Program Design – Following the directions in the assignment, clearly write up your problem design in this section and comment your pseudocode. Begin Declare......

Words: 331 - Pages: 2

Free Essay

Calculate the Usable Area in Square Feet of House. Assume That the House Has a Maximum of Four Rooms, and That Each Room Is Rectangular.

...CMIS102 Homework Assignment 1 Student Name: Clarence Loveless Class/Section: CMIS102 Professor Name: Nickolas Pitocco Assignment due date: 13 Sept 13 Problem definition: Calculate the usable area in square feet of house. Assume that the house has a maximum of four rooms, and that each room is rectangular. A. Problem Analysis 1. What is the usable living area of 4 room house (output) 2. What is the length of room 1 (length1) - input 3. What is the width of room 1 (width2) – input 4. What is the sq footage of room1 (sqft1)– float variable 5. What is the length of room 2 (length2) - input 6. What is the width of room 2(width2) – input 7. What is the sq footage of room2(sqft2) – float variable 8. What is the length of room 3(length3) – input 9. What is the width of room 3(width3) - input 10. What is the sq footage of room3(sqft3) – float variable 11. What is the length of room 4 (length4)- input 12. What is the width of room 4 (width4)– input 13. What is the sq footage of room4(sqft4) – float variable 14. Add each sq footage together for total living area – float variable Formulas – sq footage=length*Width Total living area=sq footage1+sqfootage2+sqfootage3+sqfootage4 B. Program Design – Following the directions in the assignment, clearly write up your problem design in this section and comment your pseudocode. Input......

Words: 478 - Pages: 2

Free Essay

House Square Footage Calculator

...Homework Assignment # 1 Marvin Sankar CMIS102 Professor Khattab  A. 1/23/2015 Program Description: The objective of this program is to calculate the square footage of a house with up to 3 rooms. The program will ask the user to enter the width and length of each room in feet. The expected output will multiplying the length and width of each room and then summing the square footage of each room to yield the total square footage of the house. Program name: House Square Footage calculator Analysis: We will use sequential statements All variables will be float We will define these variables: Total_SqFt Room_1_L Room_2_L Room_3_L Room_1_W Room_2_W Room_3_W Input: The user will be prompted to enter the room dimension for each room individually (up to three rooms) “Enter Length and Width of room 1” “Enter Length and Width of room 2” “Enter Length and Width of room 3” Ouput: The output will be defined as the total square footage of the house and will use the input provided by the user to calculate output with this formula: The Square footage of the house will be calculated by this formula: SqFt = (Room_1_L x Room_1_W) + (Room_2_L + Room_2_W) + (Room_3_L x Room_3_W) The output message will display a message “Total Square foot of the house is: SqFt” Test Plan Three test cases will be done Test Case # | Input | Expected Output | 1 | Room1: length=10, width=14; Room 2: length=9, width=10; Room 3: length=12, width=12; | 374 square feet | 2 |......

Words: 850 - Pages: 4

Free Essay

C++ Case Statements

...CMIS102 Homework Assignment 2 (Worth 13% of your grade) Student Name: Ariel Cintron Class/Section: CMIS102 / 6383 Professor Name: Ronald Mcfarland Assignment due date: Feb 01 2012 Problem definition: Calculate the total price to purchase all the components required to build a state-of-the-art gaming computer from components available on the internet. A. Problem Analysis – Following the directions in the assignment, clearly write up your problem analysis in this section. The input consists of computer base price (CompPrice), the CPU choice (CPU_choice), the RAM choice (RAM_choice), and the Graphics Card choice (VideoCard_choice). Once the customer has entered a choice of an option, the program will determine the corresponding cost of that option: CPU_cost, RAM_cost, VideoCard_cost. The only item output is the computer selling price (ComputerPrice). To determine the ComputerPrice, the following computation is: ComputerPrice = CompPrice + CPU_cost + RAM_cost + VideoCard_cost. B. Program Design – Following the directions in the assignment, clearly write up your problem design in this section and comment your pseudocode. Things the program must do: 1. Input the computer base price 2. Process the various options to compute the additional costs 3. Total all the costs 4. Display the final selling price The main Module will contain the following submodules: Compute_CPU_Cost Compute_RAM_Cost ...

Words: 908 - Pages: 4

Premium Essay

Adas

...CMIS102 Homework Assignment 1 (Worth 13% of your grade) Student Name: Class/Section: CMIS 102 Professor Name: Assignment due date: 03 November 2013 Problem definition: Calculate the usable area in square feet of house. Assume that the house has a maximum of four rooms, and that each room is rectangular. A. Problem Analysis – Following the directions in the assignment, clearly write up your problem analysis in this section. a. What is the required output? i. Total square feet of the house. TotalSquareFeet b. What is the necessary input? i. Length of each room. Length# ii. Width of each room. Width# iii. Square feet of each room. SquareFeet# c. How will we obtain the required output from the given input? i. SquareFeet# = Length# x Width# ii. TotalSquareFeet = SquareFeet1 + SquareFeet2 + SquareFeet3 + SquareFeet4 d. Variable names and definitions. i. TotalSquareFeet = The total square feet of the house. ii. Length# = The length of the room with the corresponding number. iii. Width# = The width of the room with the corresponding number. iv. SquareFeet# = The total square feet of the room with the corresponding number. B. Program Design – Following the directions in the assignment, clearly write up your problem design in this section and comment your pseudo......

Words: 257 - Pages: 2

Free Essay

Data

...CMIS102 Homework Assignment 1 (Worth 13% of your grade) Student Name: Jorge Mazuera Class/Section:1202CMIS102 6380 Professor Name: Dr. Noni Bohonak Assignment due date: 08/31/2014 Problem definition: Calculate the usable area in square feet of house. Assume that the house has a maximum of four rooms, and that each room is rectangular. A. Problem Analysis – Following the directions in the assignment, clearly write up your problem analysis in this section. Problem= We are trying to find out what the square footage of each room of a house and the square footage of the entire house. The input would include the length and width of each room and the formula to find the answer. The output would need to include the square footage of each room and the total square footage of the house. If all the code is properly executed, we will be able to input any sized room and quickly be able to find the square footage. B. Program Design – Following the directions in the assignment, clearly write up your problem design in this section and comment your pseudocode. Main module Declare EntireHouse As String Declare LivingRoom, As Float Declare Kitchen As Float Declare BedRoom As Float Declare BathRoom As Float Write “Square Footage Program” Write “This program computes the square footage of individual rooms and” Write “the total area of houses” Call Input Data module Call Perform Calculations module Call Output Results module End......

Words: 283 - Pages: 2

Premium Essay

Cmis Hw1

...CMIS102 Homework Assignment # 1 Student Name: Matt Marshall Problem definition: Calculate the usable area in square feet of a house. Assume that the house has a maximum of four rooms, and that each room is rectangular. A. Problem Analysis – Desired Output: The sum of the two integers Required Input: 2 integers. a and b Calculations: A*B=C B. Program Design – This program will sum two integer numbers to receive a third integer number. //Declare variables Declare a,b,c as Integer // Set values of Integers Set a= Set b= Set c=a+b // Print c Print a,b,c C. Program Comments and Test Data – Following the directions in the assignment, include your test data and expected results in this section. (The Comments section is for specifics about how you designed your program, any problems you had, how you solved them, lessons learned, and how you would improve the program if you had more time. This is normally used by programmers who may come back to the program later.) Table 1. Include your test data table here. Show at least 3 examples sets of test data. Test data is normally designed before the program is written. It is used after the program is completed to test and ensure it works as it was designed to work. |Test Case # |Input |Expected Output | |1 ...

Words: 348 - Pages: 2

Premium Essay

Homework1

...CMIS102 Homework Assignment 1 (Worth 13% of your grade) Problem definition: Calculate the usable area in square feet of house. Assume that the house has a maximum of four rooms, and that each room is rectangular. A. Problem Analysis – Following the directions in the assignment, clearly write up your problem analysis in this section. In order to determine the usable area of the house I must first find out what is the total square feet area of each of the four rooms. I know that to get the area of each room I have to multiply LengthFeet X WidthFeet and that will give me the area of a 1 Room. Then I must do this to all four rooms, therefore, the results of the total area of the four rooms will give me the usable area of the house. My output variables are: UsableAreaFeet (float variable), AreaOfRoomFeet (float variable). Input variables: Length (float variable) and Width (float variable) and AreaOfRoomFeet (float variable). Formulas need it: AreaOfRoomX=Length X Width Where X is rooms 1-4, UsableAreaFeet=AreaOfRoom1Feet + AreaOfRoom2Feet + AreaOfRoom3Feet + AreaOfRoom4Feet B. Program Design – Following the directions in the assignment, clearly write up your problem design in this section and comment your pseudocode. PseudoCode Input Data Module: Input: LengthFeet, WidthFeet, AreaOfRoomXFeet Perform Calculations Module Compute: AreaOfRoomXFeet Here the formula use will be AreaOfRoomX = Length X Width Compute: UsableAreaFeet Here I will......

Words: 560 - Pages: 3

Free Essay

Problem Definition: Write a Program That Would Calculate and Display the Results for the Multiplication Table for Values Ranging from 1 to 100.

...CMIS102 Homework Assignment 3 Problem definition: Write a program that would calculate and display the results for the multiplication table for values ranging from 1 to 100. A. Problem Analysis – Following the directions in the assignment, clearly write up your problem analysis in this section. In order to write this program, two variables, ROWNUM and COLUMNNUM, will be used with nested repetition loop to complete the necessary calculations. ROWNUM will be used in an outerloop and contain numbers between1-10 and COLUMNNUM will be used in an innerloop and contain numbers between 1-10. For each iteration of the outerloop, the inner loop will be executed 10 times and the product of ROWNUM*COLUMNNUM will produce the multiplication table of ROWNUM. The ROWNUM and COLUMNNUM variables will be incremented by 1in each iteration of loops. The new line will be printed to display the multiplication table for each value of ROWNUM in a separate line. This table shows the outputs that will be generated from the calculations: 1 2 3 4 5 6 7 8 9 10 2 4 6 8 10 12 14 16 18 20 3 6 9 12 15 18 21 24 27 30 4 8 12 16 20 24 28 32 36 40 5 10 15 20 25 30 35 40 45 50 6 12 18 24 30 36 42 48 54 60 7 14 21 28 35 42 49 56 63 70 8 16 24 32 40 48 56 64 72 80 9 18 27 36 45 54 63 72 81 90 10 20 30 40 50 60 70 80 90 100 B.......

Words: 565 - Pages: 3

Free Essay

Homework

...CMIS102 Homework Assignment 1 (Worth 13% of your grade) Student Name: Class/Section:CMIS102 / Data-type, input/output Professor Name: Assignment due date: 11/4/2012 Program Analysis In this program the overall goal is to obtain the overall square feet in a four bedroom house. In order to calculate the correct output we will need the correct input. I will obtain the required output from the given input by multiplying length x width to find the number of square feet in each room and then add the amount of the four rooms together. • Room1 = Room1Length * Room1Width • Room2 = Room2Length * Room2Width • Room3 = Room3Length * Room3Width • Room4 = Room4Length * Room4Width • TotalSquareFeet = Room1 + Room2 + Room3 + Room4 Input data: Input the variable Room1Length, Room1Width, Room2Length, Room2Width, Room3Length, Room3Width, Room4Length and Room4Width Calculations: TotalSquareFeet = Room1 + Room2 + Room3 + Room4 Program Design Main Module Declare Room1 As Float Declare Room2 As Float Declare Room3 As Float Declare Room4 As Float Write “Total Square feet Program” Call Input Data module Call Perform Calculations module Call Output results module End Program Input Data Module //Get the value of the dimensions Write “What is the length......

Words: 421 - Pages: 2

Free Essay

Calculate the Usable Area in Square Feet of House. Assume That the House Has a Maximum of Four Rooms, and That Each Room Is Rectangular.

...CMIS102 Homework Assignment 1 Student Name: Neal Fowler Class/Section: CMIS 102 Section 6385 Professor Name: Marie Arvi Assignment due date: 6 January 2014 Problem definition: Calculate the usable area in square feet of house. Assume that the house has a maximum of four rooms, and that each room is rectangular. A. Problem Analysis: What is the required output? Total square footage of a house (in square feet) What is the necessary input? Room 1, 2, 3, and 4 length and width. How will we obtain output from input? Each room length and width input multiplied. Next all four rooms total add together for output. B. Program Design: 1. Input data: Input the variables Rm1L, Rm1W, Rm2L, Rm2W, Rm3L, Rm3W, Rm4L, Rm4W 2. Perform calculations: where… Rm1sqft = Rm1L * Rm1W, Rm2sqft = Rm2L * Rm2W, Rm3sqft = Rm3L * Rm3W, Rm4sqft = Rm4L * Rm4W, where… Housesqft = Rm1sqft + Rm2sqft + Rm3sqft + Rm4sqft 3. Output results: Display the total square feet (Housesqft) of the house // House Measurement Computation // Programmer: Neal Fowler Main module // Declare Variables Declare Rm1L Declare Rm1W Declare Rm2L Declare Rm2W Declare Rm3L Declare Rm3W Declare Rm4L Declare Rm4W Declare Rm1sqft Declare Rm2sqft Declare Rm3sqft Declare Rm4sqft Declare Housesqft Write “Home Measurement Program” Write “This program computes the total” Write “square feet (living space) of a house.” Call Input Data module Call Perform Calculations module Call Output......

Words: 472 - Pages: 2

Free Essay

Calculate Square Footage

...CMIS102 Homework Assignment 1 (Worth 13% of your grade) Student Name: Angelica Hines Class/Section: CMIS 102.1202.7983 Professor Name: Ronald McFarland Assignment due date: 04/01/2012 Problem definition: Calculate the usable area in square feet of house. Assume that the house has a maximum of four rooms, and that each room is rectangular. A. Problem Analysis – Following the directions in the assignment, clearly write up your problem analysis in this section. In this program the overall goal is to obtain the usable area in square feet in a house. The results or overall goal would be considered the required output. To obtain the required output we would need the necessary input. The necessary information regarding the house is that it contains a maximum of four rooms that are rectangular in shape. I will obtain the required output from the given input by multiplying length x width to find the number of square feet in each rectangular room. Once the combined square footage of each room is determined this will give me the amount of usable living space. We would need to know each room length and width, then calculate each rooms area and then find the sum of all four rooms. Area of Room 1= Length1 x Width1 Area of Room 2= Length2 x Width2 Area of Room 3= Length3 x Width3 Area of Room 4= Length4 x Width4 Area of Room 1 + Room 2 + Room 3 =Room 4 = Total Square footage B. Program Design – Following the directions in the assignment,......

Words: 643 - Pages: 3

Free Essay

Housesqft Cmis102

...CMIS102 Homework Assignment 1 (Worth 13% of your gradeProblem definition: Calculate the usable area in square feet of house. Assume that the house has a maximum of four rooms, and that each room is rectangular. A. Problem Analysis – Following the directions in the assignment, clearly write up your problem analysis in this section. The primary goal is to calculate the square footage of a 4-room house. In order to do this, we need to know each room’s length and width, then calculate the area of each room and lastly find the sum of the area of each of the four rooms.  * Area of Room1=length1*width1 * Area of Room2=length2*width2 * Area of Room3=length3*width3 * Area of Room4=length4*width4 Total Number of Square Feet = Area of Room1+ Area of Room2+ Area of Room3+ Area of Room4 B. Program Design – Following the directions in the assignment, clearly write up your problem design in this section and comment your pseudocode. We need to output the value of the total area of the house after finding and summing the areas of each room. For this to be possible, we will define the input and output variables. Variables Length of Room 1 = length1 (Float) (followed to) Length of Room 4 = length4 (Float) Width of Room 1 = width1 (Float) (followed to) Width of Room 4 = width4 (Float) Additional Variables Area = length*width Area1 = length1 * width1 (float variable) Area2 = length2 * width2 (float variable) Area3 = length3 *......

Words: 640 - Pages: 3

Free Essay

Calculate the Usable Area in Square Feet of House. Assume That the House Has a Maximum of Four Rooms, and That Each Room Is Rectangular

...CMIS102 Homework Assignment 1 Student Name: Abel Patrick Assizo Class/Section: CMIS 102 Section 7986 Professor Name: Jose Romero Assignment due date: April 1, 2012 Assignment: Calculate the usable area in square feet of house. Assume that the house has a maximum of four rooms, and that each room is rectangular. 1) Problem analysis This Program is intended to compute the area of a house composed of four rectangular rooms. Indeed, for this problem, we need to output the value of the total area of the house after finding and summing the areas of each room. For this to be possible, we will define output and input variables. Therefore, for this program, we will need to output the value of the following variable: * The value of the area of the house total_area (a Float variable) We will also need to input the value of the length and width of each room, subsequently the following variables: * The value of the length of the first room length1 (a Float variable) * The value of the width of the first room width1 (a Float variable) * The value of the length of the second room length2 (a Float variable) * The value of the width of the second room width2 (a Float variable) * The value of the length of the third room length3 (a Float variable) * The value of the width of the third room width3 (a Float variable) * The value of the length of the fourth room length4 (a Float variable) * The value of the width of the fourth room...

Words: 801 - Pages: 4