Skip to content

Ramblebot complete,#2

Open
AhmedIhsan123 wants to merge 12 commits intogrc-cohort-22:mainfrom
AhmedIhsan123:main
Open

Ramblebot complete,#2
AhmedIhsan123 wants to merge 12 commits intogrc-cohort-22:mainfrom
AhmedIhsan123:main

Conversation

@AhmedIhsan123
Copy link
Copy Markdown

Check it out.

@auberonedu
Copy link
Copy Markdown

Don't worry about failing test, it's because the test runner on GitHub has a very old version of Java.

return null;

// Create a list to store all the words
List<String> list = 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.

Nice use of interface type

Comment on lines +136 to +139
List<String> list = neighborMap.get(context.getLast());

// Return a random word that could follow in regards to context
return list.get((int)(Math.random() * (list.size())));
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Nice!

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