there is no A-Z after downcase
You didn't mention that words in array have to be in the same order as they are in the string
This comment is hidden because it contains spoiler information about the solution
there is no reason to rescue, nil will be returned anyway
I have a similar result except that I used map instead of each, because the value that will be returned after calling phone_kids is the array of results of each kid call and not an array of kids all the time
Why did you make buzz and fizz symbols instead of strings?
no need to write .to_a, the answer is always an array return at the end can be omitted
no need in local variable
You are repeating n.to_s so often that you could simply do n = n.to_s at the beginning to write less code
there is no need in exclamation mark in reverse methods
similar variation to your solution would be: n.to_s(2).split('').sum(&:to_i)
todo comment is no longer relevant, since the implementation is already there
Loading collection data...
there is no A-Z after downcase
You didn't mention that words in array have to be in the same order as they are in the string
This comment is hidden because it contains spoiler information about the solution
there is no reason to rescue, nil will be returned anyway
I have a similar result except that I used map instead of each, because the value that will be returned after calling phone_kids is the array of results of each kid call and not an array of kids all the time
Why did you make buzz and fizz symbols instead of strings?
This comment is hidden because it contains spoiler information about the solution
no need to write .to_a, the answer is always an array
return at the end can be omitted
no need in local variable
You are repeating n.to_s so often that you could simply do n = n.to_s at the beginning to write less code
there is no need in exclamation mark in reverse methods
similar variation to your solution would be:
n.to_s(2).split('').sum(&:to_i)
todo comment is no longer relevant, since the implementation is already there