// Copyright 2013 The Go Authors. All rights reserved.// Use of this source code is governed by a BSD-style// license that can be found in the LICENSE file.packagemainimport"fmt"funcmain(){// const string OMITconstsample="\xbd\xb2\x3d\xbc\x20\xe2\x8c\x98"// const string OMITfmt.Println("Println:")// println OMITfmt.Println(sample)// println OMITfmt.Println("Byte loop:")// byte loop OMITfori:=0;i<len(sample);i++{fmt.Printf("%x ",sample[i])}// byte loop OMITfmt.Printf("\n")fmt.Println("Printf with %x:")// percent x OMITfmt.Printf("%x\n",sample)// percent x OMITfmt.Println("Printf with % x:")// percent space x OMITfmt.Printf("% x\n",sample)// percent space x OMITfmt.Println("Printf with %q:")// percent q OMITfmt.Printf("%q\n",sample)// percent q OMITfmt.Println("Printf with %+q:")// percent plus q OMITfmt.Printf("%+q\n",sample)// percent plus q OMIT}