vendredi 30 septembre 2016

Read a specific line in a file java [duplicate]

This question already has an answer here:

I am a beginner programmer and a I have trouble finding a simple way to read a line from a file.

There is a file in the second directory called "first". My code generates a random number, (ex. 9) and has to print that line of that file. The files won't ever exceed 100 lines. I would like to know how to print line number 9 from the file "first".

Remember that I have very little experience and that there are no stupid questions.




Aucun commentaire:

Enregistrer un commentaire