Warning: The magic method Slickr_Flickr_Plugin::__wakeup() must have public visibility in /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php on line 152
‘#mastery22’ Articles at TC101 Fall 2015
Introduction to Programming Python and C++

# Masteries 22 and 25

Here is my video to masteries 22 and 25

# #Mastery22

On Python, there are three different ways of make a repetitive task: for statement: for loops are the best option when you want to repeat an action for a fixed amount of elements. while statement: The best moment for use a while loop is when you want a program to run a certain condition is […]

# Mastery 22: When to use what type of repetition in a program

Here is the video: https://youtu.be/lRInwlGtymU
Thanks for watching!!

# Mastery #22 – When to use what type of repetition in a program

Here’s my video of me explaining mastery #22. Enjoy.

# Mastery 21 and 22

Here is the lin to the video:   Here is the link for the Prezi presentation from Fernanda Zapata: https://prezi.com/uzl5h9nlzwti/masteries-21-22/?utm_campaign=share&utm_medium=copy Here is the link to the website that gives you more information: http://c.conclase.net/curso/?cap=024

# Recursion and Loops

Here is my video tutorial about recursion and when to use what kind of loop:

# Masteries 21 & 22

Use of recursion for repetitive algorithms
When to use what type of repetition in a program

# Matery 22

On this mastery I’ll show you when to use what type of repetition in a program.

For the purpose of this mastery, we’ll focus on while and for loops because they are the easiest and most used ones.

On mastery 19 we learned how to use a while loop. The while loop consists of something that will happen WHILE a condition is given. For example: WHILE x is greater or equal than 0, something will happen, and this process will continue to happen WHILE this condition is true.

On mastery 20 we learned how to use a for loop.

A FOR loop is a type of loop which allows you to give specific conditions to it, and then repeat when this conditions are true.

Now, while and for may be seem like they are the same, but they certainly ain’t. The main difference between them is that FOR loops will continue happening for a given number of iterations.

As you may recall, functions often use a for loop because of the iteration part. In someway, FOR loops are “better” when dealing with functions, while WHILE loops are great to work with inside main().

# #Mastery22 – When to use what type of repetition in a program

Hello this is about repetitions in programs. A repetition is an integral part of a programming language. These repetitive operation or sentences are named as ”iterations”. An iteration means that a process is repeated again and again. To do this, the principal method is the loop which are commonly used in any programming work. Loops are used when wanting to reduce a process into simpler coding, when something has to be repeated on and on.  Loops are the basis of the repetition in any programming language.  There are different types of loops of course, like while, for etc.

While- a code of bock that uses a while has to include a condition to be valid and for it to compile and work correctly. They allow the program to perform a particular action while a set condition is true.

Break and continue- It can be used to end a loop before some condition. If you type continue, the loop continues to do its work, obviously.

This processes enables the programs to repeat an action as long as a particular set condition remains true.

A for loop is another kind of repetition when coding in c++. A for loop can provide the beginning of the loop, obviously a condition and updates like…

( i=0 ; i

# Mastery 18 & 22

Mastery 18 – Nesting of conditional statements Here’s WSQ 09, in which I use nesting of conditional statements. Mastery 22 -When to use what type of repetitions on a program. There are two types of loops in Python, while and for loops, when you want to make a repetition indefinite number of times to use […]

#### What should you work on?

Week #12 and more partial exams for you.