And since I'm a fan of lifelong learning, I have to admit to not having known 
that println() was a builtin until this post. Thanks! That does un-complicate 
it somewhat.

> On Mar 26, 2020, at 10:34 AM, Sebastien Binet <bi...@cern.ch> wrote:
> 
> On Thu, Mar 26, 2020 at 3:29 PM David Riley <fraveyd...@gmail.com> wrote:
> [...]
> But:
> 
> - You still need to import something just to print a line, and it is 
> confusingly (to the novice) named "fmt"
> - You still need to declare a function called main(), and most brand-new 
> programmers don't understand functions yet, so this becomes a "wave the dead 
> chicken at it just right" thing
> - Semicolons are still there under the surface, but they're inserted by the 
> lexer, and when they get inserted can be really mysterious and trip a lot of 
> people up
> 
> In contrast, in Python (3, in this case), it is:
> 
> print("Hello, world!")
> 
> to be fair, in Go, "hello world" can be reduced to:
> 
> package main
> func main() {
>     println("hello world")
> }
> 
> that's usually how I start my Go-based lecture.
> (and then, 2-3 lectures/hands-on sessions after that, I do introduce 'import 
> "foo"')
> 
> -s

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/D503437D-FA3F-4388-973D-4DF4BC1F73A8%40gmail.com.

Reply via email to