title: printing the octal number through printf command
body: <p>I have been trying to understand the printf functionality for octal numbers.
  if I write the code as:</p>
  
  <pre><code>int main()
  {
    char *s = "\123";
    printf("%s",s);
  }
  </code></pre>
  
  <p>It gives me an output as S which actually is correct since ASCII of S is 123 in octal.
  But my question is, how does the compiler identifies the sequence of numbers to convert from octal. for example:</p>
  
  <pre><code>char *s = "\123456" 
  </code></pre>
  
  <p>would give an output as S456</p>
  
  <p>Is it that it takes max 3 numbers for octal conversion???</p>
  
  <p>Is there any max limit within which the octal should be given (the max 3 digit octal number would be 777)</p>
  
  <p>Now since there are max 255 ascii characters (octal 377) then when i try to print 777 it prints a typical � ascii character, which is presume may be since there is no such ascii assigned to this number. 
  Also is this functionality a compiler/os dependent???</p>
  
  <p>I hope am pretty much clear since its my first question here :-)</p>