Standard library / math

math.E

Base of natural logarithms. Expected stdout: '2.718282\n'.

Formal Syntax & Structure

go syntaxgo
const E   = 2.71828182845904523536028747135266249775724709369995957496696763

Working Example

Example Snippetgo
package main
import (  "fmt"  "math")
func main() {  fmt.Printf("%.6f\n", math.E)}
Go Reference