Algorithmique (9/14) - Boucle Pour - Structures itératives

28 Nov 2018 · 4 min
4:21

In this French lecture, the instructor revisits iterative structures in algorithms, first recalling the While (TantQue) loop and its three essential components: counter initialization, loop condition, and counter update. He then introduces the For (Pour) loop, showing how these three elements can be combined into a single line, with explicit start, end, and step (pas) values, and noting that an implicit step of 1 can be omitted. The speaker demonstrates the For loop by re‑implementing the power‑calculation algorithm, highlighting its clearer syntax when the number of iterations is known. He discusses the criteria for choosing between While and For: For is preferred when the iteration count is predetermined (e.g., power, factorial, fixed‑size averages), while While is suited for loops that continue until a condition is met without a known count. The lecture also covers nested For loops, exemplified by generating the multiplication table from 1 to 9, and mentions that the upcoming lesson will address the Repeat (Répéter) structure.

Chapters

More from Yamossoun

8:56
youtube.com

Compteur synchrone - Logique séquentielle

2w ago
11:58
youtube.com

Compteur asynchrone et diviseur de fréquence - Logique séquentielle

3w ago
11:37
youtube.com

Les registres (parallèle et à décalage) - Logique séquentielle

1mo ago
6:14
youtube.com

Bascule T (Toggle) - Logique séquentielle

1mo ago
12:05
youtube.com

Bascule JK - Logique séquentielle

1mo ago
9:17
youtube.com

Bascule D flip-flop active sur front montant - Logique séquentielle

1mo ago
10:08
youtube.com

Bascule D Latch - Logique séquentielle

1mo ago
8:13
youtube.com

Bascule RS - Logique séquentielle

1mo ago
5:04
youtube.com

Logique séquentielle - Introduction

2mo ago
1:15
youtube.com

Le codeur - Logique combinatoire #codeur #logique #circuit #booleanlogic

2mo ago
1:56
youtube.com

Algorithme de calcule de la racine carrée par dichotomie #dichotomy #squareroot #algorithm

3mo ago
See all content