Created
May 8, 2015 00:29
-
-
Save shichao-an/2eae3c34f717fb5bdde8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"fmt" | |
"reflect" | |
) | |
func main() { | |
var x float64 = 3.4 | |
fmt.Println(reflect.TypeOf(x)) // float64 | |
fmt.Println(reflect.ValueOf(x)) // <float64 Value> | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment