Apply Today to our Front End or Back End Programs & check out our scholarships!

Final Project

Back to Curriculum Index

Your Challenge

Write a Ruby program that asks a user several questions, or the same question several times. Collect each response they provide in an array.

After the user has answered all the questions, print out a sentence to report back to the user what their answers were!

If you're feeling creative, you could ask your user for words (various parts of speech even) and write a MadLib. If you're not feeling super creative, you could use one of these ideas: ask the user what they have in their fridge, or what their favorite songs are, or the names of each of their friends.

🌶 Challenges 🌶

  • Alphabetize the array before you print out the final sentence to your user. This resource can help you get started!
  • Modify your program to ask two sets of questions; maybe something like "What is the name of a friend?" and "What is the age of that friend?". Organize the data in two arrays. Print out a sentence that accurately groups the names and ages!
  • If you are really feeling confident and want to push the envelope, click on the the Extensions section, read to teach yourself about iteration, and work to implement that into your current project.

Next: Info Session & Panel