I am fairly new to Java and I would like to ask how is it possible to get the last line of a text file using Java? For example, the contents of the text file would be something like:
001,abc,[email protected],123456,President
002,xxx,[email protected],xxx,Member
What I am trying to get is the userID of the users (eg:001). I already know how to read from a text file normally, but what I need is the last line from the text file so that I can give users incrementing IDs.