This language bar is your friend. Select your favorite languages!
Edit summary for version 3 :

Version 2

Version 3

Idiom #59 Write to standard error stream

Print the message "x is negative" to standard error (stderr), with integer x value substitution (e.g. "-2 is negative").

Idiom #59 Write to standard error stream

Print the message "x is negative" to standard error (stderr), with integer x value substitution (e.g. "-2 is negative").

Imports
import "os"
Imports
import "os"
Code
fmt.Fprintf(os.Stderr, "%d is negative", x)
Code
fmt.Fprintln(os.Stderr, x, "is negative")
Demo URL
https://play.golang.org/p/aygrTLLV85
Demo URL
https://play.golang.org/p/6x6amJrySS