Standard library / math/cmplx
cmplx.Inf()
Returns complex infinity with both components positive infinity. Expected stdout: 'true\n'.
Formal Syntax & Structure
go syntaxgo
func Inf() complex128Return Value
complex128
Returns complex infinity with both components positive infinity.
Working Example
Example Snippetgo
package main
import ( "fmt" "math/cmplx")
func main() { z := cmplx.Inf() fmt.Println(cmplx.IsInf(z))}