+ Term Fall 2012 CIS 2110 HW #1 Test Data CIS Department Courses Summary Student ID- Code 111 222 333 444 555 666 777 -1
-
- Site Admin
- Posts: 899566
- Joined: Mon Aug 02, 2021 8:13 am
+ Term Fall 2012 CIS 2110 HW #1 Test Data CIS Department Courses Summary Student ID- Code 111 222 333 444 555 666 777 -1
Assignment: For the problem described in Homework 1: 1. Include a copy of your I/O Design (you may modify/improve what you turned in for homework 1). 2. Create a data dictionary for your project (see below) 3. Develop the Essential Model- a hierarchy model. 4. Develop an Implementation Model using a Flowchart
simple Eglish notes initialize variables -> input term output term input studentlD output studentID if(studentID=(-1),stop and report, continue)-> 111 !=-1, therefore continue input gpa output gpa Inputs term input hoursCompleted output hoursCompleted Initialize variables input term output term input studentID output studentID check for the kill flag input goa output gpa Input hoursCompleted output hoursCompleted update the count by 1 totalStudentcount= totalStudentCount + 1 => totalStudentCount++ => 0+1 update the totalHours4AllStude total Hours4AllStudent - totalHours4AllStudents + hoursCompleted - 0 + 80-80 update the averageStudentHour avergeStudent HoursCompleted = totalHours4AllStudents/totalStudentCount=80/1 = 80 check to see if the input just ent if(gpa >highGPA, highGPAStudentID=studentID, skip) => 2.00 >0 => true, so highGPAstudentID = studentID check to see if the input just ent if(gpa >highGPA, highGPA = gpa, skip] => 2.00 >0 => true, so highGPA =gpa input gpa output gpa input hoursCompleted output hoursCompleted Fall2012 input studentip output studentID if(studentID=(-1),stop and report, continue)-> 222 1-1, therefore continue studentID gpa 111 222 2.00 hoursCompleted 2.85 totalStudentcount= totalStudentCount+ 1 => totalStudentCount++ => 1+1 total Hours4AllStudent = totalHours4AllStudents + hoursCompleted = 80 +100 = 180 avergeStudentHoursCompleted = totalHours4AllStudents/totalStudentCount = 180/2 = 90 if(gpa >highGPA, highGPAStudentID-studentID, skip) ->2.85 > 2.00 -> true, so highGPAstudentID-studentID if(gpa >highGPA, highGPA = gpa, skip) => 2.85>2.00 => true, so highGPA = gpa 80 100 Working memory totalStudentCount 0 1 2 totalHours4AllStudents 0 80 180 averageStudentHoursCompleted 0 80 90 hig
input studentID output studentID if(studentID = (-1),stop and report, continue)=> 333 != -1, therefore continue input gpa output gpa input hoursCompleted output hoursCompleted 333 input studentID output studentID if(studentID = (-1),stop and report, continue)=> 444 != -1, therefore continue input gpa output gpa input hoursCompleted output hoursCompleted totalStudentcount= totalStudentCount + 1 => totalStudentCount++ => 2+1 totalHours4AllStudent = totalHours4AllStudents + hoursCompleted = 180 + 20 = 200 avergeStudentHoursCompleted = totalHours4AllStudents / totalStudentCount = 200/3 = 66.67 if(gpa >highGPA, high GPAStudentID = studentID, skip) => 3.55 > 2.85 => true, so high GPAstudentID = studentID if(gpa >highGPA, highGPA = gpa, skip) => 3.55 > 2.85 => true, so highGPA = gpa 3.55 444 3.55 totalStudentcount= totalStudentCount + 1 => totalStudentCount++ => 3+1 totalHours4AllStudent = totalHours4AllStudents + hoursCompleted = 200 + 102 = 302 avergeStudentHoursCompleted = totalHours4AllStudents / totalStudentCount = 302/4 = 75.5 if(gpa >highGPA, highGPAStudentID = studentID, skip) => 3.55 > 3.55 => true, so highGPAstudentID = studentID if(gpa >highGPA, highGPA = gpa, skip) => 3.55 > 3.55 => true, so highGPA = gpa 20 102 3 4 200 302 66.67 75.5