0 votes
1 view
in Java by (13.1k points)

I was trying a program in command line over Windows 10 using the following command:

javac MyFirstProgram.java

But it is throwing an error :

'javac' is not recognised as an internal or external command, operable program or batch

Can anyone help me with this?

1 Answer

0 votes
by (26.7k points)

Basically, we need to set the path, to run the following execution command:

1. First, have your javac path by using Windows Explorer and copy the path address.

2. After that, go to the control panel, then go to environment variables, and there we need to add the path address followed by the semicolon.

Note - Do not delete the path which exists.

I hope this will help.

Want to know more about Java? Prefer this tutorial on Core Java Tutorial.

Want to become a Java Expert? join Java Training now!!  

Related questions

Welcome to Intellipaat Community. Get your technical queries answered by top developers !