Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hari's solution #83

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Hari's solution #83

wants to merge 3 commits into from

Conversation

hkdahal
Copy link

@hkdahal hkdahal commented Jan 19, 2018

@@ -14,13 +14,21 @@ def run!
loop do
user_input = get_user_input
p speak(user_input)
break if @bye_counter == 3
Copy link
Member

Choose a reason for hiding this comment

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

Since @bye_counter is compared with 3 in two places, consider extracting a method to combine the duplication. In an actual application, this sort of duplication might lead to a bug when one is not kept in sync with the other.

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