Created a file using Java io package and by using scanner class saves some data in the file from console