title: Different sizes of same strings - Telnet programming
body: <p>I have been trying to create an iphone app sending telnet command. However what puzzling me is that the sizes of certain strings are so much different, particularly when they include \n or \r. I listed out a few examples. Please assist.</p>
  
  <pre><code>const char *a = "play 25\n";
  int sizeBitA1 = sizeof(a);  // 8 units
  int sizeBitA2 = sizeof("play 25\n"); // 9 units
  const char *b = "\r\n";
  int sizeBitB1 = sizeof(b);  // 8 units
  int sizeBitB2 = sizeof("\r\n");  // 3 units
  </code></pre>