Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Go Language Go Language Overview Flow Control If Statements

God, why is wrong? :@

I copied and paste the code. made some changes, and yet doesn't work D:

src/blackjack/player.go
package blackjack

import "fmt"

func PlayHand(score int) {
  if score < 17 {
    fmt.Println("hit me")
  } else if score > 21 {
    fmt.Println("bust")
  } else {
    fmt.Println("stand")
  }
}

1 Answer

Steven Parker
Steven Parker
231,269 Points

You're really close! But the challenge asked you to return those strings, not print them.

And you can just call me "Steven". :laughing:

Also, you said you "copied and paste...", but copied from where? The challenge requirements will always be a bit different from the lessons, so copying lesson code to paste in will usually not work.

When you start with C language and go to GO language, happens these things haha, thanks Steven :D