title: Golang: How can I write a map which is mixed with string and array?
body: <p>I am a beginner of <code>Go</code>.
  I wrote this code, but an error occurred.
  How should I write a map which contains <code>string</code> and <code>[]string</code> properties?</p>
  
  <pre><code>package main
  
  import (
      "fmt"
  )
  
  func main() {
      prof := make(map[string]map[string]interface{})
  
      prof["me"] = map[string]string{
          "name":       "John Lennon",
          "email":      "foobar@gmail.com",
          "phone":      "090-0000-0000",
          "occupation": []string{"Programmer", "System Engineer"},
          "language": []string{"Go", "Java", "Python", "PHP", "JavaScript", "SQL"},
          "hobby": []string{"Photography", "Traveling", "Fishing", "Eating"},
      }
  
      fmt.Println(prof)
  
  }
  </code></pre>
  
  <p>This error is from <a href="https://ideone.com/Q0roBI" rel="nofollow">Ideone</a>.</p>
  
  <pre><code># _/home/NcWlmE
  ./prog.go:14: cannot use []string literal (type []string) as type string in map value
  ./prog.go:15: cannot use []string literal (type []string) as type string in map value
  ./prog.go:16: cannot use []string literal (type []string) as type string in map value
  </code></pre>