CORRIGÉS DÉTAILLÉS - INITIATION À
L’ALGORITHMIQUE (BTS 1)
TD 2 - Calculs
1 Aire rectangle : Lire L,l → Aire=L*l → Afficher Aire
2 Moyenne : M=(n1+n2+n3)/3
3 TTC : TTC = HT + HT*0.1925
TD 3 - Conditions
1 Pair/Impair : Si N mod 2=0 alors Pair sinon Impair
2 Max : comparer successivement
3 Mention : utiliser SinonSi
TD 4 - Boucles
1 Somme : boucle Pour
2 Factorielle : produit cumulatif
3 Palindrome : inverser nombre
TD 5 - Tableaux
1 Somme tableau : boucle
2 Max tableau : comparaison
3 Recherche : boucle avec test
Mini Projet
1 Gestion notes : somme → moyenne → mention