• Get now! CIS 170 Lab 3 of 7 Link to CIS 170 Lab 3 of 7 Free version CIS 170 Lab 3 of 7 pdf guide Whoops, our bad.
  • The page you requested was not found, and we have a fine guess why. If you typed the URL directly, please make sure the spelling is correct. If you clicked on a link to get here, the link is outdated. What can you do? Have no fear, help is near! There are many ways you can get back on track with Magento Store. Go back to the previous page. Use the search bar at the top of the page to search for your products. Follow these links to get you back on track! Contact Us You will design, code, build, execute, and debug a program that will use looping to determine the final score of dives based on individual judges’ scores as well as a given dive’s degree of difficulty. Deliverables Submit the following to this week’s Dropbox: A zipped Visual Studio project folder for each programming exercise. Refer to the Deliverables section of the Week 1 iLab page for detailed instructions on how to zip a project folder. A single MS Word file named YourLastName_Lab1_ex1.docx containing the following items: The source code for each part/exercise: Your source code should use proper indentation, include meaningful comments, and be error free. Start each with a specification that includes your name, the lab and exercise number, and a description of what the program accomplishes, similar to this: /* Specification: First Name Last Name Lab 1 Exercise# This program does X */ Labeled screenshot(s) demonstrating that each exercise produces correct results NOTE: A screenshot of a window can be created by first clicking on it to activate it. Next, press the key or key combination your specific computer uses to do a “print screen” (typically the Prnt Scrn or Prnt key in combination with the ctrl or FN key). Then, click the MS Word “paste” option to paste the screenshot into the MS Word file. Objectives and Grading Lab Objectives: Become familiar with the different types of looping structures. To be able to debug a program of syntax and logic errors To be able to use the debug step-into feature to step through the logic of the program and to see how the variables change values Your lab grade will be based upon: the formatting of your source code; the use of meaningful identifiers; the extent of internal documentation; and the degree to which an exercise’s specifications are met. Preparation: If you are using the Citrix remote lab, follow the login instructions located in the iLab tab in Course Home. iLab Steps Step 1: Requirements – DIVER Scoring Program Your State Dive Association presently scores its diving competitions with pencil and paper. They would like for you to design and develop a Dive Program in C++. The paper forms that they presently use have the following: Diver’s Name, City JudgeScore1 – The scores entered are from 0 to 10. JudgeScore2
  • JudgeScore3 JudgeScore4 JudgeScore5 DegreeOfDifficulty – This is assigned once for each diver. OverAllScore – The overall score is the individual diver’s scores totaled and then divided by the degree of difficulty. The highest and lowest scores are removed as they are often skewed entries. Total the three scores left, divide them by 3, and then multiply that by the DegreeOfDifficulty. The degree of difficulty ranges from 1.00 to 1.67. Display the diver’s information and overall score. When the competition is complete, there is a summary report created that lists the total number of divers and the average of the overall scores. Lab hints: When writing this lab, use nested loops. A nested loop is when one loop is completely contained in another loop. In an inner loop, you will read the five scores one at a time. Every time you read the score (in the loop), you will compare the score to the highest so far and also to the lowest so far so you can determine the highest and lowest scores, in addition to adding the scores up one at a time. You also need to have your program process multiple divers. Put this in an outer loop. After you process the information for one diver, prompt the user if she/he wants to process another diver. Allow the user to type either a “Y†​ or “y†​ to enter another diver’s information; otherwise, exit the loop. Write an event summary by calculating and displaying the average score for all divers and the total number of divers participating. Garbage in Garbage Out (GIGO): The data being entered by the user needs to be validated. Scores by judges may range between 0 and 10. If the user enters an invalid score, display an error message, and prompt for the score again. Keep doing this until the user enters the score correctly. The degree of difficulty may range from 1.00 to 1.67. Sample output from program Report to the media Event: Diving competition Enter the diver’s name: Sue Jones Enter the diver’s city: Dallas Enter the score given by judge #1: 45 Invalid score – Please reenter (Valid Range: 0 – 10) Enter the score given by judge #1: 3 Enter the score given by judge #2: 4.5 Enter the score given by judge #3: 6.7 Enter the score given by judge #4: 89 Invalid score – Please reenter (Valid Range: 0 – 10) Enter the score given by judge #4: 8 Enter the score given by judge #5: 9.2 What was the degree of difficulty? 1.9 Invalid degree of difficulty – Please reenter (Valid Range: 1 – 1.67) What was the degree of difficulty? 2 Invalid degree of difficulty – Please reenter (Valid Range: 1 – 1.67) What was the degree of difficulty? 1.2 Diver: Sue Jones, City: Dallas Overall score was 7.68 Do you want to process another diver (Y/N)? y Enter the diver’s name: XXXXX XXXXX Enter the diver’s city: Houston Number of divers participating: 2 Average score of all divers: 7.71
  • Loop as long as there are divers to process Input diver’s name and city Initialize highest score, lowest score and total score Using a do-while loop input the 5 judge’s scores Prompt the user if she wants to process another diver Calculate the average score for all divers Display the number of divers and the average score for all divers Step 3: Create a New Project Create a new project and name it LAB3. Write your code using the Processing Logic in Step 2. Make sure to save your program. Step 4: Build Solution To compile the program, click Debug then Build solution (F7). You should receive no error messages. If you see some error messages, check the code above to make sure you didn’t key in something wrong. Once you make your corrections to the code, go ahead and click Build >> Build Solution again. Step 5: Execute the Program Once you have no syntax errors, to execute or run your program, click Debug on the menu bar and then click Start Debugging. Step 6: Capture the Output 1. Capture a screen print of your output. (Do a PRINT SCREEN and paste into an MS Word document.) 2. Copy your code and paste it into the same MS Word document that contains the screen print of your output. 3. Save the Word document as Lab03_LastName_FirstInitial. CIS 170 iLab 1 of 7 CIS 170 Week 1 – iLab 1 of 7 Week 1: Your First Program: Data Types and Expressions – iLab Objectives and Grading Lab Objectives: 1. How to create a project 2. How to enter and save a program 3. How to compile and run a program 4. Given a simple problem using input and output, be able to code and test a program that meets the specifications. 5. Be able to debug a simple program of any syntax and logic errors. Your lab grade will be based upon: Preparation:  If you are using the Citrix remote lab, follow the login instructions located in the iLab tab in Course Home. Get now! CIS 170 Lab 3 of 7 Whoops, our bad. Contact Us CIS 170 iLab 1 of 7 CIS 170 Week 1 – iLab 1 of 7
Please download to view
All materials on our website are shared by users. If you have any questions about copyright issues, please report us to resolve them. We are always happy to assist you.
...

CIS 170 Lab 3 of 7

by antoine

on

Report

Category:

Documents

Download: 0

Comment: 0

212

views

Comments

Description

Download CIS 170 Lab 3 of 7

Transcript

  • Get now! CIS 170 Lab 3 of 7 Link to CIS 170 Lab 3 of 7 Free version CIS 170 Lab 3 of 7 pdf guide Whoops, our bad.
  • The page you requested was not found, and we have a fine guess why. If you typed the URL directly, please make sure the spelling is correct. If you clicked on a link to get here, the link is outdated. What can you do? Have no fear, help is near! There are many ways you can get back on track with Magento Store. Go back to the previous page. Use the search bar at the top of the page to search for your products. Follow these links to get you back on track! Contact Us You will design, code, build, execute, and debug a program that will use looping to determine the final score of dives based on individual judges’ scores as well as a given dive’s degree of difficulty. Deliverables Submit the following to this week’s Dropbox: A zipped Visual Studio project folder for each programming exercise. Refer to the Deliverables section of the Week 1 iLab page for detailed instructions on how to zip a project folder. A single MS Word file named YourLastName_Lab1_ex1.docx containing the following items: The source code for each part/exercise: Your source code should use proper indentation, include meaningful comments, and be error free. Start each with a specification that includes your name, the lab and exercise number, and a description of what the program accomplishes, similar to this: /* Specification: First Name Last Name Lab 1 Exercise# This program does X */ Labeled screenshot(s) demonstrating that each exercise produces correct results NOTE: A screenshot of a window can be created by first clicking on it to activate it. Next, press the key or key combination your specific computer uses to do a “print screen” (typically the Prnt Scrn or Prnt key in combination with the ctrl or FN key). Then, click the MS Word “paste” option to paste the screenshot into the MS Word file. Objectives and Grading Lab Objectives: Become familiar with the different types of looping structures. To be able to debug a program of syntax and logic errors To be able to use the debug step-into feature to step through the logic of the program and to see how the variables change values Your lab grade will be based upon: the formatting of your source code; the use of meaningful identifiers; the extent of internal documentation; and the degree to which an exercise’s specifications are met. Preparation: If you are using the Citrix remote lab, follow the login instructions located in the iLab tab in Course Home. iLab Steps Step 1: Requirements – DIVER Scoring Program Your State Dive Association presently scores its diving competitions with pencil and paper. They would like for you to design and develop a Dive Program in C++. The paper forms that they presently use have the following: Diver’s Name, City JudgeScore1 – The scores entered are from 0 to 10. JudgeScore2
  • JudgeScore3 JudgeScore4 JudgeScore5 DegreeOfDifficulty – This is assigned once for each diver. OverAllScore – The overall score is the individual diver’s scores totaled and then divided by the degree of difficulty. The highest and lowest scores are removed as they are often skewed entries. Total the three scores left, divide them by 3, and then multiply that by the DegreeOfDifficulty. The degree of difficulty ranges from 1.00 to 1.67. Display the diver’s information and overall score. When the competition is complete, there is a summary report created that lists the total number of divers and the average of the overall scores. Lab hints: When writing this lab, use nested loops. A nested loop is when one loop is completely contained in another loop. In an inner loop, you will read the five scores one at a time. Every time you read the score (in the loop), you will compare the score to the highest so far and also to the lowest so far so you can determine the highest and lowest scores, in addition to adding the scores up one at a time. You also need to have your program process multiple divers. Put this in an outer loop. After you process the information for one diver, prompt the user if she/he wants to process another diver. Allow the user to type either a “Y†​ or “y†​ to enter another diver’s information; otherwise, exit the loop. Write an event summary by calculating and displaying the average score for all divers and the total number of divers participating. Garbage in Garbage Out (GIGO): The data being entered by the user needs to be validated. Scores by judges may range between 0 and 10. If the user enters an invalid score, display an error message, and prompt for the score again. Keep doing this until the user enters the score correctly. The degree of difficulty may range from 1.00 to 1.67. Sample output from program Report to the media Event: Diving competition Enter the diver’s name: Sue Jones Enter the diver’s city: Dallas Enter the score given by judge #1: 45 Invalid score – Please reenter (Valid Range: 0 – 10) Enter the score given by judge #1: 3 Enter the score given by judge #2: 4.5 Enter the score given by judge #3: 6.7 Enter the score given by judge #4: 89 Invalid score – Please reenter (Valid Range: 0 – 10) Enter the score given by judge #4: 8 Enter the score given by judge #5: 9.2 What was the degree of difficulty? 1.9 Invalid degree of difficulty – Please reenter (Valid Range: 1 – 1.67) What was the degree of difficulty? 2 Invalid degree of difficulty – Please reenter (Valid Range: 1 – 1.67) What was the degree of difficulty? 1.2 Diver: Sue Jones, City: Dallas Overall score was 7.68 Do you want to process another diver (Y/N)? y Enter the diver’s name: XXXXX XXXXX Enter the diver’s city: Houston Number of divers participating: 2 Average score of all divers: 7.71
  • Loop as long as there are divers to process Input diver’s name and city Initialize highest score, lowest score and total score Using a do-while loop input the 5 judge’s scores Prompt the user if she wants to process another diver Calculate the average score for all divers Display the number of divers and the average score for all divers Step 3: Create a New Project Create a new project and name it LAB3. Write your code using the Processing Logic in Step 2. Make sure to save your program. Step 4: Build Solution To compile the program, click Debug then Build solution (F7). You should receive no error messages. If you see some error messages, check the code above to make sure you didn’t key in something wrong. Once you make your corrections to the code, go ahead and click Build >> Build Solution again. Step 5: Execute the Program Once you have no syntax errors, to execute or run your program, click Debug on the menu bar and then click Start Debugging. Step 6: Capture the Output 1. Capture a screen print of your output. (Do a PRINT SCREEN and paste into an MS Word document.) 2. Copy your code and paste it into the same MS Word document that contains the screen print of your output. 3. Save the Word document as Lab03_LastName_FirstInitial. CIS 170 iLab 1 of 7 CIS 170 Week 1 – iLab 1 of 7 Week 1: Your First Program: Data Types and Expressions – iLab Objectives and Grading Lab Objectives: 1. How to create a project 2. How to enter and save a program 3. How to compile and run a program 4. Given a simple problem using input and output, be able to code and test a program that meets the specifications. 5. Be able to debug a simple program of any syntax and logic errors. Your lab grade will be based upon: Preparation:  If you are using the Citrix remote lab, follow the login instructions located in the iLab tab in Course Home. Get now! CIS 170 Lab 3 of 7 Whoops, our bad. Contact Us CIS 170 iLab 1 of 7 CIS 170 Week 1 – iLab 1 of 7
Fly UP