CB100

Notas, resueltos y tps de la materia Algoritmos y Estructuras de Datos
Index Commits Files Refs README
commit bf72df0e587587497dbadad2174b28c11a255df1
parent 5ad641da3d347328cc56370b34bc1456f9b858bd
Author: Martin Kloeckner <mjkloeckner@gmail.com>
Date:   Wed, 20 Mar 2024 02:30:57 -0300

Clear remaining characters after selection

On some terminals the remaining screen wasn't being cleared after a
selection was made. This commit adds an escape sequence to clear the
screen after the selection is made.

Diffstat:
Msolutions/ej11.cpp | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/solutions/ej11.cpp b/solutions/ej11.cpp
@@ -167,7 +167,7 @@ int main (void) {
         } else {
             mg = "You selected: `";
         }
-        cout << mg << menu[selected_item] << "`" << endl;
+        cout << mg << menu[selected_item] << "`\033[0J\n";
     }
 
     exit(EXIT_SUCCESS);