HelloWorld Error in the terminal

I just tried to run my HelloWorld prgroram from the command prompt but I got the below error

Try the new cross-platform PowerShell https://aka.ms/pscore6

PS C:\Users\mpmor\IdeaProjects\HelloWorld\src\com\mpmgemcompany> javac Main.java
javac : The term ‘javac’ is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1

  • javac Main.java
  •   + CategoryInfo          : ObjectNotFound: (javac:String) [], CommandNotFoundException
      + FullyQualifiedErrorId : CommandNotFoundException
    
    

PS C:\Users\mpmor\IdeaProjects\HelloWorld\src\com\mpmgemcompany>

Hi @mpmorris82. Two possibilities, (1) Java is not installed or (2) it is not included in your environment PATH variable.

You can download it from here: Java Downloads | Oracle

Also check your PATH variable (on windows you find this in Environment Variables) to see if the file path to your java /bin directory is included. If not add it and you should be good to go!