Answered step by step
Verified Expert Solution
Question
1 Approved Answer
PROGRAMMING LANGUAGE USED IS RUBY Object Oriented Programming with Ruby: (10 pts) Write a Ruby method that takes an array of strings as an argument,
PROGRAMMING LANGUAGE USED IS RUBY
Object Oriented Programming with Ruby: (10 pts) Write a Ruby method that takes an array of strings as an argument, sorts it alphabetically, iterates and uses a code block to display each string element along with its characters count. For example, if passing the following argument array ["Adam", "Eve", "Mark","Franklin", "John"], then the output should be: Adam, ch count 4 Eve, ch count 3 Franklin, ch count-8 John, ch_count 4 Mark, ch_count- 4 Object Oriented Programming with Ruby: (10 pts) Write a Ruby method that takes an array of strings as an argument, sorts it alphabetically, iterates and uses a code block to display each string element along with its characters count. For example, if passing the following argument array ["Adam", "Eve", "Mark","Franklin", "John"], then the output should be: Adam, ch count 4 Eve, ch count 3 Franklin, ch count-8 John, ch_count 4 Mark, ch_count- 4Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started