> For the complete documentation index, see [llms.txt](https://yingshaoxo.gitbook.io/go-tutorial-for-pythoner/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://yingshaoxo.gitbook.io/go-tutorial-for-pythoner/the-structure-of-go/functions.md).

# Functions

## Codes:

```go
package main

import "fmt"

func add1(x int, y int) int {
    return x + y
}

func add2(x, y int) int {
    return x + y
}

func main() {
    fmt.Println(add1(2, 3))
    fmt.Println(add1(3, 3))
}
```

## Output:

```
5
6
```
