Skip to content · ⁨Passer au contenu⁩

Reverse in place · ⁨Inverser in place⁩

English

Reverse in place

Reverse a C-string in place — change the characters in the same array rather than building a new string. The classic move: a left index at the start and a right index at the end, swap them, then step both toward the middle until they meet.

Français

Inverser in situ

Inversez une chaîne C in situ — modifiez les caractères dans le même tableau plutôt que de construire une nouvelle chaîne. Le mouvement classique : un index gauche au début et un index droit à la fin, échangez-les, puis avancez les deux vers le milieu jusqu'à ce qu'ils se rencontrent.

Log in or create account · ⁨Se connecter ou créer un compte⁩

IGCSE, A-Level & AP