Click me
package main
import "fmt"
func mayPanic() {
panic("a problem")
}
func main() {
defer func() {
if r := recover(); r != nil {
fmt.Println("Recovered. Error:\n", r)
}
}()
mayPanic()
fmt.Println("After mayPanic()")
}
<details>
<summary>Click me</summary>
### Some Code
```golang
package main
import "fmt"
func main() {
fmt.Println("Hello, World!")
}
```
</details>
- Always have an empty line after the
</summary>
tag - Always have an empty line after each
</details>
tag