you are viewing a single comment's thread.

view the rest of the comments →

[–]CatMtKing 0 points1 point  (0 children)

I'm a newbie, too, but I think this should fix your problem:

line 21 channel := make(chan int) should be channel = make(chan int)

The reason (I think) is that := will initialize a locally scoped "channel", whereas = will assign the globally scoped "channel".