[Liu Ruiqian] ip - #103
Conversation
There was a problem hiding this comment.
Hello! Your code is generally pretty neat and readable. However, you should definitely consider organising your code, by separating relevant methods into their own classes. Rather than leaving all your code in just one file, if you were to compartmentalize related methods together into classes, it would be much easier for you to continue developing those functions, and also help you debug your program better. Aside from those, watch out for minor coding standard violations.
| // import Duke.Function.*; | ||
| // import Duke.Task.*; | ||
| import java.util.Scanner; | ||
| // import java.util.List; |
There was a problem hiding this comment.
It's best to remove any comments that don't serve an explanatory purpose (i.e. they don't elaborate on what the code is doing), including commented-out code.
| private static final int ITEM_DATA_COUNT = 3; | ||
|
|
||
| private static final String LEFTPAR = "["; | ||
| private static final String RIGHTPAR = "] "; |
There was a problem hiding this comment.
Good use of constant naming conventions!
| } | ||
| } | ||
|
|
||
| private static void initItemBook() { |
There was a problem hiding this comment.
Watch out for differing levels of abstraction in your code.
| } | ||
|
|
||
| private static String[] splitCommandWordAndArgs(String rawUserInput) { | ||
| final String[] split = rawUserInput.trim().split("\\s+", 2); |
There was a problem hiding this comment.
Consider simplifying code expressions that might be overly complicated, by breaking them down into multiple lines of code that are easier to read and debug. It would help others in understanding certain parts of your code more.
| showToUser(ERROR_MESSAGE,DIVIDER); | ||
| } | ||
|
|
||
| public static void addDeadlineItem(String commandArgs){ |
There was a problem hiding this comment.
Code organisation is important; you could perhaps better organise your code by segregating related methods into their own classes
# Conflicts: # docs/README.md
No description provided.