+ 2

Please help me with my code, can't fix the errors.

Java OOP, console based inventory management project https://code.sololearn.com/ciKHVkk52SCR/?ref=app

31st Oct 2021, 12:49 AM
Альфья
Альфья - avatar
4 ответов
+ 3
I have noticed some of the mistakes Are you trying this code on ide . Remember that if you made multiple classes in a single file then u can have only one public class if your two or more classes will be public it will give you errors . Then in all System.out.println lines u have written printIn capital (i) it should be small (L) this one(l) Line number 17 ...20.....24..... line number 44 your this Statement should be in block like this u have used semicolon then u have written statements it should be like this private static void displayOption(){ String Option[]=("Add Single Product","Add Box Product","Exit"); System.out.printIn("Options:"); } and here in String array u need to use curly braces instead of round brackets then in line number 50 you have used for loop and u put semicolon then your loop will terminate for (String brand:manager.getBrand()); System.out.printIn("\n"+ brand);
31st Oct 2021, 6:56 AM
A S Raghuvanshi
A S Raghuvanshi - avatar
+ 4
Thank you
31st Oct 2021, 1:43 AM
Альфья
Альфья - avatar
+ 3
Sorry there too many errors to give you a quick answer. Here are some errors you have. 1. You have some typos in your code like Public instead of public. 2. Check your brackets. Are all open brackets have a closing one. 3. \ <-- this is a escape character. You used it sometimes wrong. 4. And check your code on missing semicolons( ; ). There are more errors but fix it step by step. Good luck 😉
31st Oct 2021, 1:42 AM
Stefanoo
Stefanoo - avatar
+ 3
♨️♨️ Thank you. Actually It is four file, 1 main class and 3 sub classes. I just make it in one file to make it easier in tracking error. Thank you again.
31st Oct 2021, 7:07 AM
Альфья
Альфья - avatar