![]() Here's how I tried to run the files in cmd: java Main Sortchoice Selection SelectionSort Insertion InsertionSort Exchange ExchangeSortĪnd cmd says: exception in thread "main" : main (wring name: myjava/Main)Īt 1(Nativ. (I havent finished the syntax for the next two sorting.) Here's how I tried to compile the files: javac Main.java The problem sets in when I tried to run them. So I tried to save the files in sun>sdk>jdk>bin, and from there I tried to compile the files, and it was fine. but it says that "'javac' is not recognized as an internal or external command, operable program or batch file." ![]() In cmd, I typed the path where my NetBeans project was saved and I tried to compile the files using javac. I tried to write the program in NetBeans - thinking that later I could simply run the program in cmd using javac. our professor specifically told us to use object oriented programming in Java, and that she wants to see a main class plus the different classes that would do the sorting. The program is about using the different types of sorting (specifically Selection, Insertion, Exchange, Quick, and Heap sorting). ![]() My professor asked us to create a Java program that would be able to run in command prompt but could also be opened using NetBeans.
0 Comments
Leave a Reply. |