title: Tour of Go exercise #23: rot13Reader
body: <p>I'm trying to solve the Tour of Go exercise <a href="https://tour.golang.org/methods/23" rel="noreferrer">rot13Reader</a>:</p>
  
  <p>Here is my solution:</p>
  
  <pre><code>package main
  
  import (
      "io"
      "os"
      "strings"
  )
  
  type rot13Reader struct {
      r io.Reader
  }
  
  func rot13(x byte) byte {
      switch {
      case x &gt;= 65 &amp;&amp; x &lt;= 77:
          fallthrough
      case x &gt;= 97 &amp;&amp; x &lt;= 109:
          x = x + 13
      case x &gt;= 78 &amp;&amp; x &lt;= 90:
          fallthrough
      case x &gt;= 110 &amp;&amp; x &gt;= 122:
          x = x - 13
      }
      return x
  }
  
  func (r13 *rot13Reader) Read(b []byte) (int, error) {
      n, err := r13.r.Read(b)
      for i := 0; i &lt;= n; i++ {
          b[i] = rot13(b[i])
      }
      return n, err
  }
  
  func main() {
      s := strings.NewReader("Lbh penpxrq gur pbqr!")
      r := rot13Reader{s}
      io.Copy(os.Stdout, &amp;r)
  }
  </code></pre>
  
  <p>It returns <code>You prnpxrq tur poqr!</code>, that means only the first word of "Lbh penpxrq gur pbqr!" is cracked. How can I crack the whole sentence? </p>