Skip to content
masterclass Buddy

Go · Function

fmt.Println

fmt.Println formats any number of values with their default formats, writes them to standard output, separates them with spaces, and adds a newline. It returns the byte count and any write error.

Last updated

Syntax

func Println(a ...any) (n int, err error)

In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.

Subscribe
  • fmt.Print
  • fmt.Printf
  • fmt.Fprintln
  • fmt.Sprintln
  • fmt.Appendln

Source: src/fmt/print.go - The Go Programming Language. Checked 2026-11-03.