LineNumberReader class in java

LineNumberReader class in java LineNumberReader is a character input stream that keeps track of the number…