This video shows how to read and write text files. Two programs are used to demonstrate each of these techniques.
Further information can be found in these videos; • Java - showInputDialog + Writing text files and • Java - Reading multiple field text files . These show how to get user input and read/write to and from text files. As a bonus, the first video also shows how to ensure that names start with capital letters and then have lower case letters. This is called proper case in programming.