📥 | Simple chanel solution | 100%
\ntype FooBar struct {\n\tn int\n    ch1 chan struct{}\n    ch2 chan struct{}\n}\n\nfunc NewFooBar(n int) *FooBar {\n\treturn &FooBar{\n        n: n,\n        c
```\ntype FooBar struct {\n\tn int\n    ch1 chan struct{}\n    ch2 chan struct{}\n}\n\nfunc NewFooBar(n int) *FooBar {\n\treturn &FooBar{\n        n: n,\n        ch1: make(chan struct{}, 1),\n        ch2: make(chan struct{}, 1),\n    }\n}\n\nfunc (fb *FooBar) Foo(printFoo func()) {\n\tfor i := 0; i < fb.n; i++ {\n        fb.ch1 <- struct{}{}\n\t\t// printFoo() outputs "foo". Do not change or remove this line.\n        printFoo()\n        fb.ch2 <- struct{}{}\n\t}\n}\n\nfunc (fb *FooBar) Bar(printBar func()) {\n\tfor i := 0; i < fb.n; i++ {\n        <-fb.ch2\n\t\t// printBar() outputs "bar". Do not change or remove this line.\n        printBar()\n        <-fb.ch1\n\t}\n}\n```
['Concurrency', 'Go']