Skip to content

[JThh] ip#364

Open
JThh wants to merge 65 commits into
nus-cs2103-AY2223S2:masterfrom
JThh:master
Open

[JThh] ip#364
JThh wants to merge 65 commits into
nus-cs2103-AY2223S2:masterfrom
JThh:master

Conversation

@JThh
Copy link
Copy Markdown

@JThh JThh commented Jan 30, 2023

DukeBro

“Try harder, fail harder, and win harder.” – Myself (source)

What you need to be successful is simply a task manager - helps you take down all your deadlines and not miss any of them.

  • Feature 1: text-based
  • Feature 2: low learning curve
  • Feature 3: fast to pick up and use for programmers

All you need to do is,

  1. download it from here.
  2. double-click it.
  3. add your tasks.
  4. let it manage your tasks for you 😉

And it is FREE!

Features:

  • Managing tasks
  • Managing deadlines
  • Reminders (coming soon)

If you Java programmer, you can use it to practice Java too. Here's the main method:

public class Main {
    public static void main(String[] args) {
        Application.launch(MainApp.class, args);
    }
}

Copy link
Copy Markdown

@NappySprout NappySprout left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code is neatly written and the switch statement is methodic.

The classes present like Task has been abstracted out so splitting them into different files will not be too troublesome and will be easy for you.

Comment thread src/main/java/Duke.java Outdated
DateTimeFormatter read_fmt = DateTimeFormatter.ofPattern("yyyy-MM-dd HHmm");
DateTimeFormatter print_fmt = DateTimeFormatter.ofPattern("MMM dd yyyy");
try {
LocalDate lt = LocalDate.parse(s, read_fmt);
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible to make the argument more expressive?

Comment thread src/main/java/Duke.java Outdated

@Override
public String toString() {
return "[D]" + super.toString() + " (by: " + by + ")";
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To keep it simple you can use string formatting to prevent accumulation of '+' in string concatenation

int i = 461012;
System.out.format("The value of i is: %d%n", i);

Comment thread src/main/java/Duke.java Outdated

public static class Task {
protected String description;
protected boolean isDone;
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good job at consistent naming of the booleans!

Comment thread src/main/java/Duke.java Outdated


public class Duke {
public static ArrayList<Task> todos = new ArrayList<>();
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good naming of arrays and making them plural!

Comment thread src/main/java/Duke.java Outdated
import java.util.Scanner;
import java.io.File;


Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remember to separate the files and provide javadoc when you reach the appropriate stages 😄

Comment thread src/main/java/Duke.java Outdated
@@ -96,6 +96,7 @@ public DukeEmptyTaskException (String msg) {
public static String parse_date(String s) {
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of "parse_date", perhaps you could rename it to "parseDate", which conforms to the coding standard?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants