github.com/aykevl/tinygo@v0.5.0/testdata/print.go (about)

     1  package main
     2  
     3  func main() {
     4  	// test basic printing
     5  	println("hello world!")
     6  	println(42)
     7  	println(100000000)
     8  
     9  	// check that this one doesn't print an extra space between args
    10  	print("a", "b", "c")
    11  	println()
    12  	// ..but this one does
    13  	println("a", "b", "c")
    14  
    15  	// print integers
    16  	println(uint8(123))
    17  	println(int8(123))
    18  	println(int8(-123))
    19  	println(uint16(12345))
    20  	println(int16(12345))
    21  	println(int16(-12345))
    22  	println(uint32(12345678))
    23  	println(int32(12345678))
    24  	println(int32(-12345678))
    25  	println(uint64(123456789012))
    26  	println(int64(123456789012))
    27  	println(int64(-123456789012))
    28  
    29  	// print float64
    30  	println(3.14)
    31  
    32  	// print complex128
    33  	println(5 + 1.2345i)
    34  
    35  	// print interface
    36  	println(interface{}(nil))
    37  
    38  	// print map
    39  	println(map[string]int{"three": 3, "five": 5})
    40  
    41  	// TODO: print pointer
    42  
    43  	// print bool
    44  	println(true, false)
    45  }