String Values in Ruby
In this guide you will learn how to build a string from a collection and put it in single quotes around each element.
Guide Tasks
  • Read Tutorial
  • Complete the Exercise

Summary

Build a string from a collection and put single quotes around each element.

Exercise Description

"In this exercise you will build a string from a collection and put single quotes around each element"

Example

'arr = %w{my set of words}'
-> expect(string_values(arr)).to eq("'my', 'set', 'of', 'words'")

Real World Usage

This exercise will help you be able to put single quotes around each element in a string.

Test Cases

Code File