Skip to content

Derusted!#3

Open
Jameson789 wants to merge 6 commits intoauberonedu:mainfrom
Jameson789:main
Open

Derusted!#3
Jameson789 wants to merge 6 commits intoauberonedu:mainfrom
Jameson789:main

Conversation

@Jameson789
Copy link
Copy Markdown

No description provided.

Copy link
Copy Markdown
Owner

@auberonedu auberonedu left a comment

Choose a reason for hiding this comment

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

Nice job! See comments below

Comment thread src/MapPractice.java Outdated
// Create a HashMap with String keys and Integer values and
// assign it to a variable of type Map

HashMap<String, Integer> map = new HashMap<String, Integer>();
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Remember to use interface types here (Map)

Comment thread src/SetPractice.java Outdated
public static void main(String[] args) {
// Create a HashSet of Strings and assign it to a variable of type Set

HashSet<String> set = new HashSet<String>();
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Remember to use interface types here (Set)

Comment thread src/StringPractice.java Outdated
}
// Create an ArrayList of Strings and assign it to a variable

ArrayList<String> list = new ArrayList<String>();
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Remember to use interface types here

Comment thread src/StringPractice.java Outdated

String test1 = "Jameson";
String test2 = "James";
if(test1 == test2){
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

.equals should be used for checking String equality (see reminder in the code below.

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.

2 participants