Created
          September 6, 2019 22:52 
        
      - 
      
 - 
        
Save joshuaaguilar20/7346d94d65fb3483ac84b0fd2f70d2b2 to your computer and use it in GitHub Desktop.  
    Printing Numbers From String to Byte to Hex, Binary 
  
        
  
    
      This file contains hidden or 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
    
  
  
    
  | func main() { | |
| s:= "A" | |
| bs:= []byte(s) | |
| fmt.Println(bs) | |
| n:=bs[0] | |
| fmt.Printf("%T \n", n) | |
| fmt.Printf("%b \n", n) | |
| fmt.Printf("%#X\n", n) | |
| } | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment