Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> Oh, and I think he missed the most surprising thing about Go for newcomers: that "if" creates scope!

Go is block scoped, and if statements are blocks. I don't see this as surprising.

I agree some set operations would be nice, maybe using an interface like Sort, but you can use a map as a basic generic set data structure. This is how many language implement a set anyway.



Go is block scoped, and if statements are blocks. I don't see this as surprising.

I meant surprising for someone used to Python, like the article author. I'm surprised he didn't mention it.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: