How to clean console in java | Sololearn: Learn to code for FREE!
Nouvelle formation ! Tous les codeurs devraient apprendre l'IA générative !
Essayez une leçon gratuite
0

How to clean console in java

you know that, in C and C++ languages in windows, we can use this code to clean the console : system("cls"); but how about in java? is there any method for it? or is there any way to clean the console?

23rd Feb 2018, 2:06 PM
MS Kashef
MS Kashef - avatar
2 Réponses
23rd Feb 2018, 2:36 PM
Pehl Em
0
I finally did it with code below: new ProcessBuilder.("cmd","/c","cls").inheritIO().start().waitFor();
7th Jan 2019, 5:17 PM
MS Kashef
MS Kashef - avatar