title: oct 911:08 am (2 of 16) - bristol community...
TRANSCRIPT
![Page 1: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/1.jpg)
The Smartboard crashed and I lostthe images from the 12:30 class.
This shows a solution to the problemwe worked on last class last week.
Title: Oct 910:48 AM (1 of 16)
![Page 2: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/2.jpg)
Title: Oct 911:08 AM (2 of 16)
![Page 3: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/3.jpg)
Title: Oct 911:19 AM (3 of 16)
![Page 4: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/4.jpg)
Title: Oct 911:22 AM (4 of 16)
![Page 5: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/5.jpg)
When you set up a loop you need to handlethe three criteria listed below.
Title: Oct 911:28 AM (5 of 16)
![Page 6: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/6.jpg)
The do has no condition so the contents of the loop isexecuted once and then the while checks to see if theloop should be executed again.
Title: Oct 911:30 AM (6 of 16)
![Page 7: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/7.jpg)
Test the one where the condition was at thetop of the loop we find that it would not enterthe loop if we entered 0.
Title: Oct 911:31 AM (7 of 16)
![Page 8: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/8.jpg)
This program has a couple of alerts to showdata at a certain point an excellent debugging technique.
Title: Oct 911:33 AM (8 of 16)
![Page 9: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/9.jpg)
Title: Oct 911:33 AM (9 of 16)
![Page 10: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/10.jpg)
I entered 10, 20, 30 so far and I will enter 40 and 50 nefore the loop ends.
Title: Oct 911:34 AM (10 of 16)
![Page 11: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/11.jpg)
Title: Oct 911:38 AM (11 of 16)
![Page 12: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/12.jpg)
Title: Oct 911:42 AM (12 of 16)
![Page 13: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/13.jpg)
1)
2)
3)
class asked to add code to tell which playerwas the winner
Title: Oct 911:50 AM (13 of 16)
![Page 14: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/14.jpg)
An example that might help.
Title: Oct 911:57 AM (14 of 16)
![Page 15: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/15.jpg)
Title: Oct 912:01 PM (15 of 16)
![Page 16: Title: Oct 911:08 AM (2 of 16) - Bristol Community Collegecisweb.bristolcc.edu/~pgrocer/audio_smartboardF18/CIS120/c12011Oct918.pdfThe Smartboard crashed and I lost the images from](https://reader033.vdocuments.us/reader033/viewer/2022060819/609841cd7bb20c1dee36da37/html5/thumbnails/16.jpg)
Title: Oct 912:19 PM (16 of 16)