🤑 Join the Treehouse affiliate program and earn 25% recurring commission!

New No-Code Track! 🚀 New videos dropping every week—start learning today!

🌟 Dreaming of a bright future? 🎓 Ask about the Treehouse Scholarship program! 🚀

✨ Earn college credits in Cybersecurity, JS, HTML, CSS and Python

  • Treehouse Logo
  • Plans
    Chevron
    • For Individuals
    • For Businesses
    • For Schools
    • For Libraries
    • For Military
  • Library
    Chevron
    • All Courses
    • Tracks
    • College Credit
  • Techdegree
    Chevron
    • Overview
    • Front End Development
    • Full Stack JavaScript
    • Data Analysis
    • UX Design
    • Python
  • Community
    Chevron
    • Community Projects
    • Live Sessions
    • Code Adventures
    • Discord
    • Forum
    • Success Stories
    • Treehouse Links
    • 100 Days of Code
  • Resources
    Chevron
    • Career Toolbox
    • CodeForward
    • Free Treehouse Near Me
    • Jobs
    • Blog
    • Support
    • About
  • For Individuals For Businesses For Schools For Libraries For Military
  • All Courses Tracks College Credit
  • Overview Front End Web Development Full Stack JavaScript Python Development Data Analysis UX Design
  • Community Projects Live Sessions Code Adventures Discord Forum Success Stories Treehouse Links 100 Days of Code
  • Career Toolbox CodeForward Free Treehouse Near Me Jobs Blog Support About
  • Sign In
  • Free Trial
Instagram Twitter Facebook YouTube LinkedIn
    • Newest
      • Newest
      • Active
      • Unanswered
      • Featured
    • All Topics
      • All Topics
      • • General Discussion
      • • AI
      • • Android
      • • APIs
      • • Coding for Kids
      • • College Credit
      • • Computer Science
      • • CSS
      • • Data Analysis
      • • Databases
      • • Design
      • • Development Tools
      • • Digital Literacy
      • • Game Development
      • • Go Language
      • • HTML
      • • Java
      • • JavaScript
      • • Learning Resources
      • • Machine Learning
      • • No-Code
      • • PHP
      • • Professional Growth
      • • Python
      • • Quality Assurance
      • • React
      • • Ruby
      • • Security
      • • Swift
  • John McBride
    PLUS
    John McBride
    Courses Plus Student 3,751 Points

    I think the answer is as below: def to_s puts "Name: " + @name + ", Balance: " + balance end

    Posted August 28, 2018 10:53am by John McBride
    John McBride
    Courses Plus Student 3,751 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    1 Answer

  • Richard Wentford
    Richard Wentford
    19,730 Points

    The 'to_s' method not returning the correct string format.

    Posted August 7, 2018 9:11am by Richard Wentford
    Richard Wentford
    19,730 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    1 Answer

  • Nafeez Quraishi
    Nafeez Quraishi
    12,416 Points

    Answer not being accepted

    Posted May 19, 2018 8:40am by Nafeez Quraishi
    Nafeez Quraishi
    12,416 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    2 Answers

  • chad manning
    chad manning
    2,462 Points

    Balance method not being interpolated correctly

    Posted February 28, 2018 3:20am by chad manning
    chad manning
    2,462 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    1 Answer

  • victor manda
    PLUS
    victor manda
    Courses Plus Student 2,479 Points

    Edited forgot the f after .2

    Posted February 2, 2018 7:58am by victor manda
    victor manda
    Courses Plus Student 2,479 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    1 Answer

  • victor manda
    PLUS
    victor manda
    Courses Plus Student 2,479 Points

    No exact error just try again

    Posted February 2, 2018 7:56am by victor manda
    victor manda
    Courses Plus Student 2,479 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    1 Answer

  • Ryan Dsouza
    Ryan Dsouza
    9,388 Points

    Unknown error in Console when i try doing this ruby exercise

    Posted January 28, 2018 4:10pm by Ryan Dsouza
    Ryan Dsouza
    9,388 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    2 Answers

  • David Greenstein
    David Greenstein
    6,734 Points

    Why are we able to do interpolation with balance here?

    Posted October 5, 2017 6:58am by David Greenstein
    David Greenstein
    6,734 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    1 Answer

  • Mateusz LeÅ›niak
    Mateusz Leśniak
    4,762 Points

    Can't find mistake in my code

    Posted March 30, 2017 8:55pm by Mateusz Leśniak
    Mateusz Leśniak
    4,762 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    1 Answer

  • John Baulig
    John Baulig
    9,180 Points

    to_s method

    Posted May 18, 2016 11:23am by John Baulig
    John Baulig
    9,180 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    2 Answers

  • yelmi almonte
    yelmi almonte
    10,685 Points

    Help me Please Ruby Object

    Posted December 4, 2015 2:29pm by yelmi almonte
    yelmi almonte
    10,685 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    1 Answer

  • Jared Armes
    PLUS
    Jared Armes
    Courses Plus Student 6,391 Points

    I am so terribly stuck. I have no clue what to do here.

    Posted September 3, 2015 1:43pm by Jared Armes
    Jared Armes
    Courses Plus Student 6,391 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    1 Answer

  • David Besserman
    David Besserman
    3,963 Points

    I can't understand why my method isn't correctly formated

    Posted July 7, 2015 9:21am by David Besserman
    David Besserman
    3,963 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    1 Answer

  • abdi ali
    abdi ali
    10,920 Points

    help

    Posted June 9, 2015 6:00am by abdi ali
    abdi ali
    10,920 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    2 Answers

  • Terdema Ussery
    Terdema Ussery
    2,477 Points

    not sure what I am doing wrong

    Posted May 15, 2015 6:33pm by Terdema Ussery
    Terdema Ussery
    2,477 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    2 Answers

  • Joshua Horwitz
    Joshua Horwitz
    2,384 Points

    I'm not sure what is going wrong here, everything else has been going great but I can't get this to_s to work at all.

    Posted May 13, 2015 4:13pm by Joshua Horwitz
    Joshua Horwitz
    2,384 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    1 Answer

  • Dax Allen
    Dax Allen
    4,788 Points

    Bank Account challenge problem.

    Posted March 31, 2015 4:10am by Dax Allen
    Dax Allen
    4,788 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    3 Answers

  • Ieva Salte
    Ieva Salte
    15,356 Points

    help

    Posted March 13, 2015 5:51pm by Ieva Salte
    Ieva Salte
    15,356 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    1 Answer

  • Kevin Miner
    PLUS
    Kevin Miner
    Courses Plus Student 2,831 Points

    Ruby Objects and Classes extra credit: using the inject method.

    Posted March 5, 2015 8:57pm by Kevin Miner
    Kevin Miner
    Courses Plus Student 2,831 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    1 Answer

  • GURUPRASAD NAGARAJAN
    GURUPRASAD NAGARAJAN
    7,853 Points

    def to_s doesn't work but does in my programme when I run in my terminal

    Posted January 5, 2015 5:50am by GURUPRASAD NAGARAJAN
    GURUPRASAD NAGARAJAN
    7,853 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    3 Answers

  • Milos Rujevic
    seal-mask
    .a{fill-rule:evenodd;}techdegree
    Milos Rujevic
    Full Stack JavaScript Techdegree Student 39,661 Points

    Build a Bank Account Class def to_s "Name: #{name} , Balance: #{sprintf("%0.2f", balance)}" end

    Posted December 8, 2014 9:50am by Milos Rujevic
    .a{fill-rule:evenodd;}techdegree
    Milos Rujevic
    Full Stack JavaScript Techdegree Student 39,661 Points
    • Ruby
    • Ruby Objects and Classes
    • Build a Bank Account Class
    • Printing The BankAccount

    1 Answer

Posting to the forum is only allowed for members with active accounts.
Please sign in or sign up to post.

    Treehouse

  • About
  • Blog
  • Careers
  • Community
  • Stories
  • Shop
  • Contact
  • Gift Card

See Full Catalogue

Techdegree

  • Front End Web Development
  • Full Stack JavaScript
  • Python Development
  • Data Analysis
  • UX Design

Tracks

  • Learn to Code for Beginners
  • Beginning Python
  • Beginning SQL
  • Beginning Java
  • ...see more

Courses

  • JavaScript Basics
  • Intro to HTML & CSS
  • Python Basics
  • CSS Layout
  • ...see more

Explore

  • Plans
  • Affiliates
  • Perks
  • Free Treehouse Near Me
  • Treehouse for Libraries
  • Treehouse for Businesses
  • Twitter
  • YouTube
  • Facebook
  • LinkedIn
  • Instagram
Terms & Conditions | Privacy

© 2025 Treehouse Island, Inc.