Do i have to initialize the value of N or use scanner/Integer.parseint(args[0])? How do i give the Input?

Hey @koushk
Use Scanner here