title: Number into alphabetic sequence
body: <p>So I have a situation in which I will be given a number (between 1 - 1000) and will need to convert it into a string as follows:</p>
  
  <pre><code>1  = A
  2  = B
  3  = C
  ...
  25 = Y
  26 = Z
  27 = AA
  28 = AB
  ...
  52 = AZ
  53 = BA
  54 = BB
  55 = BC
  ...
  78 = BZ
  79 = CA
  80 = CB
  ...
  702 = ZZ
  703 = AAA
  </code></pre>
  
  <p>So far I have this, but I'm getting the wrong answers:</p>
  
  
  
  <pre><code>count_to_string = function(count) {
      var div = Math.floor(count/26);
      var rem = count % 26; 
      ll = '';
      if (div &gt; 0) ll = ll + String.fromCharCode('A'.charCodeAt() + (div-1));
      return ll + String.fromCharCode('A'.charCodeAt() + (rem-1));
  };
  </code></pre>
  
  <p>running it with input of 26 gives output: A@</p>