Search for tag: "loops"

Cantu @ 2022 NNCI REU Convocation

2022 NNCI REU Convocation at the University of Louisville, Kentucky; Rodolfo Cantu, 2022 CNF REU Intern with Prof. Amal El-Ghazaly (Cornell)

From  Melanie-Claire Mallison 8 plays

Lesson 30.5 Selection Sort

In the previous video we saw that insertion sort is not an ideal sorting algorithm. In this video we try our hand at another algorithm: selection sort. This is another simple algorithm that may be…

From  Hannah Lee 36 plays

Lesson28.8 List Comprehension (OPTIONAL)

This video is not optional because the material is advanced. It is optional because this video series has run long and this topic is less important for you to know. When we are done with out…

From  Hannah Lee 25 plays

Lesson 26.8 The Game of Pig

With while-loops we can now write some super complex programs – once that we way more sophisticated than what we have done before. In this video we show how to create a complete dice game with…

From  Hannah Lee 63 plays

Lesson 26.6 Mutable While-Loops

In this video we show that the one place we typically prefer while-loops is when we are modifying a list or other mutable iterable. While we did see how to do this with for-loops (by looping over…

From  Hannah Lee 67 plays

Lesson 26.5 While-Loops vs For-Loops

We can always replace for-loops with while-loops, but should we? In this video we talk about the trade-offs of the two control structures and why it might be better to use over the other.

From  Hannah Lee 72 plays

Lesson 26.3 While-Loop Ranges

While-loops require additional patterns beyond the simple accumulator pattern that we used in for-loops. In this video, we talk about the first such pattern, which is replacing the range iterator.…

From  Hannah Lee 73 plays

Lesson 26.2 While-Loop Traces

While-loops can do everything that a for-loop can (and more) but they are much harder to use. That is why, in this video, we talk about how to debug a while-loop before we talk about how to write…

From  Hannah Lee 80 plays

Lesson 26.1 The While-Loop

In this video we talk about the while-loop and explain why it is necessary. In particular, there are types of iteration that are not possible with the for-loop.

From  Hannah Lee 81 plays

Zoom Oct. 27. Nested Lists and Dictionaries

This presentation explores the last built-in (as opposed to user-defined) types in this course. These types are often used to store data in files.We actually had an (accidental) sneak peak at these…

From  Hannah Lee 33 plays

Lesson 18.5 Immutable Table Functions

In this video we show how to write an immutable function on a table of data. In most ways this is no different than writing an immutable function on a list. Except that this time we may need multiple…

From  Hannah Lee 74 plays

Lesson 17.4 Divide and Conquer

Recursion has many, many uses. But one of the most popular applications is divide-and-conquer. In this video we introduce this new concept and show how we will use to solve several problems on…

From  Hannah Lee 114 plays

Lesson 17.3 Recursion and the Call Stack

Because a recursive function calls itself, it will have multiple call frames on the call stack. In this video we show exactly why we should be concerned about this and why it will affect our function…

From  Hannah Lee 147 plays

Lesson 16.7 For-Loops and Testing

Another control-structure means another video on testing. But if you have following the Rule of Numbers, you will discover that you have enough tests for your for-loop. Instead, as we show in this…

From  Hannah Lee 72 plays

CS 6120: Lesson 7: Interprocedural Analysis

From  Adrian Sampson 1,514 plays

CS 6120: Lesson 5: Global Analysis & Optimization

From  Adrian Sampson 1,732 plays