Presentation is loading. Please wait.

Presentation is loading. Please wait.

March 2005 1R. Smith - University of St Thomas - Minnesota QMCS 130: Today’s Class Finish up Lab 13Finish up Lab 13 Lab 14 – DetailsLab 14 – Details.

Similar presentations


Presentation on theme: "March 2005 1R. Smith - University of St Thomas - Minnesota QMCS 130: Today’s Class Finish up Lab 13Finish up Lab 13 Lab 14 – DetailsLab 14 – Details."— Presentation transcript:

1 March 2005 1R. Smith - University of St Thomas - Minnesota QMCS 130: Today’s Class Finish up Lab 13Finish up Lab 13 Lab 14 – DetailsLab 14 – Details

2 March 2005 2R. Smith - University of St Thomas - Minnesota Lab 14 Convert a typed line of text to Pig LatinConvert a typed line of text to Pig Latin –Words that start with consonants Strip the leading consonantsStrip the leading consonants Append to end of the wordAppend to end of the word Add “ay”Add “ay” –Words that start with vowels Append “way” to end of the wordAppend “way” to end of the word –Keep running until a “blank” line is typed FunctionsFunctions –Read a line of text –Test for vowel –Index of next vowel –Index of next blank

3 March 2005 3R. Smith - University of St Thomas - Minnesota Strategy: Functions to Write Argument listsArgument lists –Array –Starting index –Maybe an Ending index –Maybe something else: a test char, a destination array FunctionsFunctions –Find a character of a particular kind (vowel, consonant, start of word, end of word) –Append some characters to the end of another string –“Convert Vowel Word” function –“Convert Consonant Word” function –Readline function, like we wrote in class

4 March 2005 4R. Smith - University of St Thomas - Minnesota Strategy: Incremental Development What’s the easiest way to start?What’s the easiest way to start? –Build the ‘skeleton’ first –Add easy things, then harder things What’s the easiest conversion?What’s the easiest conversion? What’s the first step in making a conversion happen?What’s the first step in making a conversion happen?

5 March 2005 5R. Smith - University of St Thomas - Minnesota Creative Commons License This work is licensed under the Creative Commons Attribution-Share Alike 3.0 United States License. To view a copy of this license, visit http://creativecommons.org/licenses/by- sa/3.0/us/ or send a letter to Creative Commons, 171 Second Street, Suite 300, San Francisco, California, 94105, USA.


Download ppt "March 2005 1R. Smith - University of St Thomas - Minnesota QMCS 130: Today’s Class Finish up Lab 13Finish up Lab 13 Lab 14 – DetailsLab 14 – Details."

Similar presentations


Ads by Google