Question : on an console app, once i display a question before a console.readline, how to add a default value?

hello experts,

i'm working on a console app, i ask several questions to the user.

i want to ask a question and propose an answer, sort of by default answser, as follow, i ask the person a questions and i propose the 3, i want the person to "press enter" to validate this "3" which is a by default answer:

how many apples in your pockets  ? 3


how can i manage this, thank you in advance.

Answer : on an console app, once i display a question before a console.readline, how to add a default value?

Random Solutions  
 
programming4us programming4us