Skip to content

grep: add exercise - #1429

Merged
sjwarner-bp merged 7 commits into
exercism:masterfrom
FridaTveit:GrepAddNewExercise
Apr 23, 2018
Merged

sjwarner-bp merged 7 commits into
exercism:masterfrom
FridaTveit:GrepAddNewExercise

Conversation

@FridaTveit

Copy link
Copy Markdown
Contributor


boolean shouldInvertMatch = flags.contains("-v");
//noinspection SimplifiableConditionalExpression
return shouldInvertMatch ? !matchesPattern : matchesPattern;

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I know this can be simplified, but I think it's a lot easier to read like this. Happy to change it if people want though! 🙂

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I'm happy to keep this as it is - I like readability! 🙂

Comment thread config.json
"filtering",
"searching"
],
"unlocked_by": "robot-name",

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Feel free to suggest a different difficulty or a different exercise for it to be unlocked by! 🙂

I thought 5 might be a good difficulty since it has some complexity but not too much. And robot-name is also about strings and pattern matching (it has difficulty 5 as well) so I thought it might be a good fit for unlocked by 🙂

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I agree - this seems like a good fit!

@FridaTveit FridaTveit changed the title WIP grep: add exercise grep: add exercise Apr 21, 2018

@sjwarner-bp sjwarner-bp left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks for the new exercise @FridaTveit!

I've left one comment but I am happy with this 🙂

Comment thread exercises/settings.gradle Outdated
include 'word-search'
include 'wordy'
include 'zipper'
include 'grep'

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Are these exercises meant to be alphabetised? 🙂

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yes they are, thanks for reminding me! Will move grep so that it's in the correct order 🙂


boolean shouldInvertMatch = flags.contains("-v");
//noinspection SimplifiableConditionalExpression
return shouldInvertMatch ? !matchesPattern : matchesPattern;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I'm happy to keep this as it is - I like readability! 🙂

Comment thread config.json
"filtering",
"searching"
],
"unlocked_by": "robot-name",

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I agree - this seems like a good fit!

@sjwarner-bp sjwarner-bp left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Yay! 🎉

@sjwarner-bp
sjwarner-bp merged commit 2754bec into exercism:master Apr 23, 2018
@sjwarner-bp

Copy link
Copy Markdown
Contributor

Thanks for the new exercise @FridaTveit - great job! 🎆

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