Question: In java language Write a program that reads a file from a standard input and rewrites the file to standard output, replacing all tab characters
In java language Write a program that reads a file from a standard input and rewrites the file to standard output, replacing all tab characters '\t' with the appropriate number of spaces. Make the distance between tab columns a constant and set it to 3. Then expand tabs to the number of spaces necessary to move to the next tab column. That may be less than three spaces. For example, consider the line containing "|\t|\t|". The first tab is changed to three spaces, the second to two spaces, and the third to one space
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
