0

Is that possible to read file over command line like this.

java Main config.txt

Main class is,

public static void main(String[] args) {
        System.out.println(args[0]);
    }

It returns "config.txt". I want to send file through command line. Is this doable?

0 Answers0