package main
import "fmt"
func main(){
var i int
var f float64
var s string
_, err := fmt.Scan(i)
if err == nil {
fmt.Println("read 1 integer: ",i)
} else {
fmt.Println("Error: ",err)
}
_, err = fmt.Scan(f)
if err == nil {
fmt.Println("read 1 float64: ",f)
} else {
fmt.Println("Error: ",err)
}
_, err = fmt.Scan(s)
if err == nil {
fmt.Println("read 1 string: ",s)
} else {
fmt.Println("Error: ",err)
}
_, err = fmt.Scanln(&s)
if err == nil {
fmt.Println("read 1 line: ",s)
} else {
fmt.Println("Error: ",err)
}
}
cGFja2FnZSBtYWluCmltcG9ydCAiZm10IgoKZnVuYyBtYWluKCl7CgkgIHZhciBpIGludAogIHZhciBmIGZsb2F0NjQKICB2YXIgcyBzdHJpbmcKICBfLCBlcnIgOj0gZm10LlNjYW4oaSkKICBpZiBlcnIgPT0gbmlsIHsKICAgIGZtdC5QcmludGxuKCJyZWFkIDEgaW50ZWdlcjogIixpKQogIH0gZWxzZSB7CiAgICBmbXQuUHJpbnRsbigiRXJyb3I6ICIsZXJyKQogIH0KICBfLCBlcnIgPSBmbXQuU2NhbihmKQogIGlmIGVyciA9PSBuaWwgewogICAgZm10LlByaW50bG4oInJlYWQgMSBmbG9hdDY0OiAiLGYpCiAgfSBlbHNlIHsKICAgIGZtdC5QcmludGxuKCJFcnJvcjogIixlcnIpCiAgfQogIF8sIGVyciA9IGZtdC5TY2FuKHMpCiAgaWYgZXJyID09IG5pbCB7CiAgICBmbXQuUHJpbnRsbigicmVhZCAxIHN0cmluZzogIixzKQogIH0gZWxzZSB7CiAgICBmbXQuUHJpbnRsbigiRXJyb3I6ICIsZXJyKQogIH0KICBfLCBlcnIgPSBmbXQuU2NhbmxuKCZzKQogIGlmIGVyciA9PSBuaWwgewogICAgZm10LlByaW50bG4oInJlYWQgMSBsaW5lOiAiLHMpCiAgfSBlbHNlIHsKICAgIGZtdC5QcmludGxuKCJFcnJvcjogIixlcnIpCiAgfQp9