Sobes.tech
Junior — Senior

What output will the console produce when running program №56

livecode

Task condition

Determine what text will be printed to the console after running the following Go code.

package main

import "fmt"
import "math"

func foo() (k float64) {
    i := 36.0
    defer func() { k = math.Sqrt(k) }()
    defer func() { k -= 11 }()
    defer func() { k += 10 }()
    return i
}

func main() {
    fmt.Println(foo())
}