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

Sockets - Maria #45

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

Sockets - Maria #45

wants to merge 3 commits into from

Conversation

MariaWissler
Copy link

@MariaWissler MariaWissler commented Feb 8, 2019

Portmanteau Generator

Congratulations! You're submitting your assignment.

Comprehension Questions

Question Answer
What went well in your code style, such as indentation, spacing, variable names, readability, etc.? What was lacking? Didnt went to far at the beginning, I feel I needed more time understanding the creation of methods and how to use them (invoke) , I feel pseudocode and today class direct me to where I started
How did creating the is_vowel? method affect your project? I think it helped me to understand how to create methods
What was your strategy for getting the correct set of letters from the first word into the portmanteau? I went back and look at the exercise we did for the password in jump start live so I feel regex could do the looping
What was your strategy for validating against inputs under 2 characters? word.length > 1
In the next project, what would you change about your process? What would you keep doing? Write pseudo code and start coding, less self doubt more google search in how to do certain things in ruby, get more familiar with visual code and indentation, honestly I found many answers in stack overflow that I used in my code

@MariaWissler MariaWissler changed the title Create generator.rb Sockets- Maria Feb 10, 2019
@MariaWissler MariaWissler changed the title Sockets- Maria Sockets - Maria Feb 10, 2019
@MariaWissler
Copy link
Author

Please refer to the last update, thank you 👍

@dHelmgren
Copy link

Portmanteau Generator

What We're Looking For

Feature Feedback
Readable code with consistent indentation See Comments, you indentation could be more consistent and your loops don't conform to our in-house-practices!
Practices using variables appropriately Yes!
Practices using conditionals appropriately Yes!
Practices iteration appropriately yes!
Practices using custom methods appropriately Partially, see comment at the end of the file!
Program validates against input under 2 characters Yes!
Takes in two inputs and creates a portmanteau Yes!

@@ -0,0 +1,29 @@
def get_the_vowel(word)
word.length > 1 && word =~ /[aeiou]/

Choose a reason for hiding this comment

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

Very fancy! Could use a comment though!

end

words = []
a = first_word.rindex(/[aeiou].*/)

Choose a reason for hiding this comment

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

again, would love a comment on this part. Most programmers don't choose to solve problems with regular expressions because they are hard to read on their own even if they are very efficient.

until get_the_vowel(second_word)
puts "Please enter a word with 2 or more characters and a vowel"
second_word = gets.chomp.downcase
end

Choose a reason for hiding this comment

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

So the indentation is conventionally done like this:

second_word = gets.chomp.downcase
until get_the_vowel(second_word)
  puts "Please enter a word with 2 or more characters and a vowel"
  second_word = gets.chomp.downcase
end 

words << word_b

puts "Word #{word_a} + #{word_b} is #{words.join("")}"

Choose a reason for hiding this comment

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

Read our instructions carefully! We asked for a run_generator method that you didn't include!

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