title: Split string and convert the substrings to integers in Go
body: <p>I've got a single variable containing something like <code>1,2,3</code>. These are actually three values, that I want to have in three variables called <code>v1</code>, <code>v2</code>, <code>v3</code> (but <strong>not</strong> in an array).</p>
  
  <p>Right now I'm doing this in the following way:</p>
  
  <pre><code>tmp := strings.Split(*w, ",")
  sw, _ := strconv.Atoi(tmp[0])
  rw, _ := strconv.Atoi(tmp[1])
  pw, _ := strconv.Atoi(tmp[2])
  </code></pre>
  
  <p>This works, although it is very repetitive and does not <em>feel</em> right in Go.</p>
  
  <p>What would be a cleaner way to solve this issue?</p>