{"id":149,"date":"2025-04-07T04:31:00","date_gmt":"2025-04-07T04:31:00","guid":{"rendered":"https:\/\/techkubo.com\/go\/?p=149"},"modified":"2025-05-26T18:06:33","modified_gmt":"2025-05-26T18:06:33","slug":"go-maps","status":"publish","type":"post","link":"https:\/\/techkubo.com\/go\/go-maps\/","title":{"rendered":"Go Maps"},"content":{"rendered":"\n<p>Maps in <strong>Go <\/strong>are collections that store data as key-value pairs, where each unique key is linked to a value. These are unordered, dynamic, and do not allow duplicate keys. The <code>len()<\/code> function gives the total number of elements in a map, and their default value is <code>nil<\/code>. Internally, maps use hash tables for efficient data management.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Creating Maps<\/h2>\n\n\n\n<h4 class=\"wp-block-heading\">Using <code>var<\/code> and <code>:=<\/code> Syntax<\/h4>\n\n\n\n<p>Maps can be initialized using the <code>var<\/code> keyword or the shorthand <code>:=<\/code> syntax.<\/p>\n\n\n\n<p><strong>Syntax<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">var mapName = map[KeyType]ValueType{key1: value1, key2: value2, ...}\nmapName := map[KeyType]ValueType{key1: value1, key2: value2, ...}\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Example<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">package main\nimport (&quot;fmt&quot;)\n\nfunc main() {\n  var motorcycles = map[string]string{&quot;brand&quot;: &quot;Honda&quot;, &quot;model&quot;: &quot;CB500F&quot;, &quot;year&quot;: &quot;2022&quot;}\n  cars := map[string]int{&quot;SUV&quot;: 5, &quot;Sedan&quot;: 3, &quot;Truck&quot;: 7}\n\n  fmt.Printf(&quot;motorcycles\\t%v\\n&quot;, motorcycles)\n  fmt.Printf(&quot;cars\\t%v\\n&quot;, cars)\n}\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Result<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">motorcycles    map[brand:Honda model:CB500F year:2022]\ncars           map[Truck:7 Sedan:3 SUV:5]\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<h4 class=\"wp-block-heading\">Using <code>make()<\/code> Function<\/h4>\n\n\n\n<p>The <code>make()<\/code> function is commonly used to create maps.<\/p>\n\n\n\n<p><strong>Syntax<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">var mapName = make(map[KeyType]ValueType)\nmapName := make(map[KeyType]ValueType)\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Example<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">package main\nimport (&quot;fmt&quot;)\n\nfunc main() {\n  var motorcycles = make(map[string]string)\n  motorcycles[&quot;brand&quot;] = &quot;Yamaha&quot;\n  motorcycles[&quot;model&quot;] = &quot;R3&quot;\n  motorcycles[&quot;year&quot;] = &quot;2021&quot;\n\n  cars := make(map[string]int)\n  cars[&quot;SUV&quot;] = 4\n  cars[&quot;Sedan&quot;] = 3\n  cars[&quot;Truck&quot;] = 6\n\n  fmt.Printf(&quot;motorcycles\\t%v\\n&quot;, motorcycles)\n  fmt.Printf(&quot;cars\\t%v\\n&quot;, cars)\n}\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Result<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">motorcycles    map[brand:Yamaha model:R3 year:2021]\ncars           map[Truck:6 Sedan:3 SUV:4]\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Creating an Empty Map<\/h2>\n\n\n\n<p>An empty map can be created using <code>make()<\/code> (preferred) or by defining its type.<\/p>\n\n\n\n<p><strong>Syntax<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">var mapName = make(map[KeyType]ValueType)  \/\/ Recommended\nvar mapName map[KeyType]ValueType          \/\/ May cause runtime panic if written to\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Example<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">package main\nimport (&quot;fmt&quot;)\n\nfunc main() {\n  var motorcycles = make(map[string]string)\n  var cars map[string]string\n\n  fmt.Println(motorcycles == nil) \/\/ false\n  fmt.Println(cars == nil)        \/\/ true\n}\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Result<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">false\ntrue\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Allowed Key Types<\/h2>\n\n\n\n<p>Map keys can be of types that support the equality operator (<code>==<\/code>), including:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Booleans<\/li>\n\n\n\n<li>Numbers<\/li>\n\n\n\n<li>Strings<\/li>\n\n\n\n<li>Arrays<\/li>\n\n\n\n<li>Pointers<\/li>\n\n\n\n<li>Structs<\/li>\n\n\n\n<li>Interfaces (if the dynamic type supports equality)<\/li>\n<\/ul>\n\n\n\n<p><strong>Invalid key types<\/strong> include:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Slices<\/li>\n\n\n\n<li>Maps<\/li>\n\n\n\n<li>Functions (since the equality operator is not defined for them)<\/li>\n<\/ul>\n\n\n\n<p>For values, any type is allowed.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Accessing Map Elements<\/h2>\n\n\n\n<p>Elements of a map can be accessed using their keys.<\/p>\n\n\n\n<p><strong>Syntax<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">value = mapName[key]\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Example<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">package main\nimport (&quot;fmt&quot;)\n\nfunc main() {\n  motorcycles := map[string]string{&quot;brand&quot;: &quot;Suzuki&quot;, &quot;model&quot;: &quot;GSX-R750&quot;, &quot;year&quot;: &quot;2023&quot;}\n  fmt.Println(motorcycles[&quot;brand&quot;])\n}\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Result<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">Suzuki\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Updating and Adding Elements<\/h2>\n\n\n\n<p>Maps allow you to update existing elements or add new ones by assigning values to keys.<\/p>\n\n\n\n<p><strong>Syntax<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">mapName[key] = value\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Example<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">package main\nimport (&quot;fmt&quot;)\n\nfunc main() {\n  cars := make(map[string]string)\n  cars[&quot;brand&quot;] = &quot;BMW&quot;\n  cars[&quot;model&quot;] = &quot;M3&quot;\n  cars[&quot;year&quot;] = &quot;2019&quot;\n\n  fmt.Println(cars)\n\n  cars[&quot;year&quot;] = &quot;2022&quot; \/\/ Updating an element\n  cars[&quot;color&quot;] = &quot;blue&quot; \/\/ Adding an element\n\n  fmt.Println(cars)\n}\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Result<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">map[brand:BMW model:M3 year:2019]\nmap[brand:BMW color:blue model:M3 year:2022]\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Removing Elements<\/h2>\n\n\n\n<p>The <code>delete()<\/code> function is used to remove elements from a map.<\/p>\n\n\n\n<p><strong>Syntax<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">delete(mapName, key)\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Example<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">package main\nimport (&quot;fmt&quot;)\n\nfunc main() {\n  motorcycles := map[string]string{&quot;brand&quot;: &quot;Ducati&quot;, &quot;model&quot;: &quot;Monster&quot;, &quot;year&quot;: &quot;2020&quot;}\n  fmt.Println(motorcycles)\n\n  delete(motorcycles, &quot;year&quot;)\n  fmt.Println(motorcycles)\n}\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Result<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">map[brand:Ducati model:Monster year:2020]\nmap[brand:Ducati model:Monster]\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Checking for Specific Elements<\/h2>\n\n\n\n<p>To check if a certain key exists, use the <code>val, ok<\/code> pattern.<\/p>\n\n\n\n<p><strong>Syntax<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">val, ok := mapName[key]\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Example<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">package main\nimport (&quot;fmt&quot;)\n\nfunc main() {\n  motorcycles := map[string]string{&quot;brand&quot;: &quot;Triumph&quot;, &quot;model&quot;: &quot;Bonneville&quot;, &quot;year&quot;: &quot;2017&quot;}\n\n  val1, ok1 := motorcycles[&quot;brand&quot;]\n  val2, ok2 := motorcycles[&quot;color&quot;]\n  _, ok3 := motorcycles[&quot;model&quot;]\n\n  fmt.Println(val1, ok1)\n  fmt.Println(val2, ok2)\n  fmt.Println(ok3)\n}\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Result<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">Triumph true\n false\ntrue\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Maps Are References<\/h2>\n\n\n\n<p>Maps are reference types, meaning changes in one variable reflect in others pointing to the same map.<\/p>\n\n\n\n<p><strong>Example<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">package main\nimport (&quot;fmt&quot;)\n\nfunc main() {\n  cars := map[string]string{&quot;brand&quot;: &quot;Tesla&quot;, &quot;model&quot;: &quot;Model 3&quot;, &quot;year&quot;: &quot;2021&quot;}\n  electricCars := cars\n\n  fmt.Println(cars)\n  fmt.Println(electricCars)\n\n  electricCars[&quot;year&quot;] = &quot;2023&quot;\n  fmt.Println(&quot;After change to electricCars:&quot;)\n\n  fmt.Println(cars)\n  fmt.Println(electricCars)\n}\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Result<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">map[brand:Tesla model:Model 3 year:2021]\nmap[brand:Tesla model:Model 3 year:2021]\nAfter change to electricCars:\nmap[brand:Tesla model:Model 3 year:2023]\nmap[brand:Tesla model:Model 3 year:2023]\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Iterating Over Maps<\/h2>\n\n\n\n<p>Maps can be iterated using the <code>range<\/code> keyword. Keep in mind the order is not guaranteed.<\/p>\n\n\n\n<p><strong>Example<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">package main\nimport (&quot;fmt&quot;)\n\nfunc main() {\n  motorcycles := map[string]int{&quot;Sport&quot;: 1, &quot;Adventure&quot;: 2, &quot;Cruiser&quot;: 3, &quot;Touring&quot;: 4}\n\n  for k, v := range motorcycles {\n    fmt.Printf(&quot;%v : %v, &quot;, k, v)\n  }\n}\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Result<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">Touring : 4, Cruiser : 3, Sport : 1, Adventure : 2,\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Iterating in a Specific Order<\/h2>\n\n\n\n<p>To maintain a specific order, use an additional structure.<\/p>\n\n\n\n<p><strong>Example<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">package main\nimport (&quot;fmt&quot;)\n\nfunc main() {\n  motorcycles := map[string]int{&quot;Sport&quot;: 1, &quot;Adventure&quot;: 2, &quot;Cruiser&quot;: 3, &quot;Touring&quot;: 4}\n  order := []string{&quot;Sport&quot;, &quot;Adventure&quot;, &quot;Cruiser&quot;, &quot;Touring&quot;}\n\n  for _, key := range order {\n    fmt.Printf(&quot;%v : %v, &quot;, key, motorcycles[key])\n  }\n}\n<\/pre><\/div>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>Result<\/strong><\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;go&quot;,&quot;mime&quot;:&quot;text\/x-go&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;Go&quot;,&quot;language&quot;:&quot;Go&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;go&quot;}\">Sport : 1, Adventure : 2, Cruiser : 3, Touring : 4,\n<\/pre><\/div>\n","protected":false},"excerpt":{"rendered":"<p>Maps in Go are collections that store data as key-value pairs, where each unique key is linked to a value. [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[1],"tags":[],"class_list":["post-149","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v24.4 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Go Maps - Go Tutorial<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/techkubo.com\/go\/go-maps\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Go Maps - Go Tutorial\" \/>\n<meta property=\"og:description\" content=\"Maps in Go are collections that store data as key-value pairs, where each unique key is linked to a value. [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/techkubo.com\/go\/go-maps\/\" \/>\n<meta property=\"og:site_name\" content=\"Go Tutorial\" \/>\n<meta property=\"article:published_time\" content=\"2025-04-07T04:31:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-05-26T18:06:33+00:00\" \/>\n<meta name=\"author\" content=\"Manong\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Manong\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/techkubo.com\/go\/go-maps\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/techkubo.com\/go\/go-maps\/\"},\"author\":{\"name\":\"Manong\",\"@id\":\"https:\/\/techkubo.com\/go\/#\/schema\/person\/b4fa2f01fa4ff2a4e98276ce47115965\"},\"headline\":\"Go Maps\",\"datePublished\":\"2025-04-07T04:31:00+00:00\",\"dateModified\":\"2025-05-26T18:06:33+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/techkubo.com\/go\/go-maps\/\"},\"wordCount\":288,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/techkubo.com\/go\/#organization\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/techkubo.com\/go\/go-maps\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/techkubo.com\/go\/go-maps\/\",\"url\":\"https:\/\/techkubo.com\/go\/go-maps\/\",\"name\":\"Go Maps - Go Tutorial\",\"isPartOf\":{\"@id\":\"https:\/\/techkubo.com\/go\/#website\"},\"datePublished\":\"2025-04-07T04:31:00+00:00\",\"dateModified\":\"2025-05-26T18:06:33+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/techkubo.com\/go\/go-maps\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/techkubo.com\/go\/go-maps\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/techkubo.com\/go\/go-maps\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/techkubo.com\/go\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Go Maps\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/techkubo.com\/go\/#website\",\"url\":\"https:\/\/techkubo.com\/go\/\",\"name\":\"Go Tutorial\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\/\/techkubo.com\/go\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/techkubo.com\/go\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/techkubo.com\/go\/#organization\",\"name\":\"Go Tutorial\",\"url\":\"https:\/\/techkubo.com\/go\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/techkubo.com\/go\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/techkubo.com\/go\/wp-content\/uploads\/sites\/13\/2025\/04\/cropped-cropped-Techkubo-logo-1-300x220-1.png\",\"contentUrl\":\"https:\/\/techkubo.com\/go\/wp-content\/uploads\/sites\/13\/2025\/04\/cropped-cropped-Techkubo-logo-1-300x220-1.png\",\"width\":300,\"height\":220,\"caption\":\"Go Tutorial\"},\"image\":{\"@id\":\"https:\/\/techkubo.com\/go\/#\/schema\/logo\/image\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/techkubo.com\/go\/#\/schema\/person\/b4fa2f01fa4ff2a4e98276ce47115965\",\"name\":\"Manong\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/techkubo.com\/go\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/21a7455736c21887b8fefe0935012d65?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/21a7455736c21887b8fefe0935012d65?s=96&d=mm&r=g\",\"caption\":\"Manong\"},\"sameAs\":[\"https:\/\/techkubo.com\"],\"url\":\"https:\/\/techkubo.com\/go\/author\/manong\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Go Maps - Go Tutorial","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/techkubo.com\/go\/go-maps\/","og_locale":"en_US","og_type":"article","og_title":"Go Maps - Go Tutorial","og_description":"Maps in Go are collections that store data as key-value pairs, where each unique key is linked to a value. [&hellip;]","og_url":"https:\/\/techkubo.com\/go\/go-maps\/","og_site_name":"Go Tutorial","article_published_time":"2025-04-07T04:31:00+00:00","article_modified_time":"2025-05-26T18:06:33+00:00","author":"Manong","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Manong","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/techkubo.com\/go\/go-maps\/#article","isPartOf":{"@id":"https:\/\/techkubo.com\/go\/go-maps\/"},"author":{"name":"Manong","@id":"https:\/\/techkubo.com\/go\/#\/schema\/person\/b4fa2f01fa4ff2a4e98276ce47115965"},"headline":"Go Maps","datePublished":"2025-04-07T04:31:00+00:00","dateModified":"2025-05-26T18:06:33+00:00","mainEntityOfPage":{"@id":"https:\/\/techkubo.com\/go\/go-maps\/"},"wordCount":288,"commentCount":0,"publisher":{"@id":"https:\/\/techkubo.com\/go\/#organization"},"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/techkubo.com\/go\/go-maps\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/techkubo.com\/go\/go-maps\/","url":"https:\/\/techkubo.com\/go\/go-maps\/","name":"Go Maps - Go Tutorial","isPartOf":{"@id":"https:\/\/techkubo.com\/go\/#website"},"datePublished":"2025-04-07T04:31:00+00:00","dateModified":"2025-05-26T18:06:33+00:00","breadcrumb":{"@id":"https:\/\/techkubo.com\/go\/go-maps\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/techkubo.com\/go\/go-maps\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/techkubo.com\/go\/go-maps\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/techkubo.com\/go\/"},{"@type":"ListItem","position":2,"name":"Go Maps"}]},{"@type":"WebSite","@id":"https:\/\/techkubo.com\/go\/#website","url":"https:\/\/techkubo.com\/go\/","name":"Go Tutorial","description":"","publisher":{"@id":"https:\/\/techkubo.com\/go\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/techkubo.com\/go\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/techkubo.com\/go\/#organization","name":"Go Tutorial","url":"https:\/\/techkubo.com\/go\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/techkubo.com\/go\/#\/schema\/logo\/image\/","url":"https:\/\/techkubo.com\/go\/wp-content\/uploads\/sites\/13\/2025\/04\/cropped-cropped-Techkubo-logo-1-300x220-1.png","contentUrl":"https:\/\/techkubo.com\/go\/wp-content\/uploads\/sites\/13\/2025\/04\/cropped-cropped-Techkubo-logo-1-300x220-1.png","width":300,"height":220,"caption":"Go Tutorial"},"image":{"@id":"https:\/\/techkubo.com\/go\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/techkubo.com\/go\/#\/schema\/person\/b4fa2f01fa4ff2a4e98276ce47115965","name":"Manong","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/techkubo.com\/go\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/21a7455736c21887b8fefe0935012d65?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/21a7455736c21887b8fefe0935012d65?s=96&d=mm&r=g","caption":"Manong"},"sameAs":["https:\/\/techkubo.com"],"url":"https:\/\/techkubo.com\/go\/author\/manong\/"}]}},"_links":{"self":[{"href":"https:\/\/techkubo.com\/go\/wp-json\/wp\/v2\/posts\/149"}],"collection":[{"href":"https:\/\/techkubo.com\/go\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/techkubo.com\/go\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/techkubo.com\/go\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/techkubo.com\/go\/wp-json\/wp\/v2\/comments?post=149"}],"version-history":[{"count":3,"href":"https:\/\/techkubo.com\/go\/wp-json\/wp\/v2\/posts\/149\/revisions"}],"predecessor-version":[{"id":211,"href":"https:\/\/techkubo.com\/go\/wp-json\/wp\/v2\/posts\/149\/revisions\/211"}],"wp:attachment":[{"href":"https:\/\/techkubo.com\/go\/wp-json\/wp\/v2\/media?parent=149"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/techkubo.com\/go\/wp-json\/wp\/v2\/categories?post=149"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/techkubo.com\/go\/wp-json\/wp\/v2\/tags?post=149"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}