title: Finding largest palindrome of a multiplication of 2 3 digits numbers limitation
body: <p>Why does the following code stop at the palindrome of value: <strong>580085</strong> while the correct answer for the question is <strong>906609</strong> result of this multiplication: 993*913</p>
  
  <pre><code>    #!/usr/bin/env python
      # Find the largest palindrome made from the product of two 3-digit numbers.
  
      # Reverse algorithm
      def flipNumber( number ):
          nmbList     = list(str(number))
  
          i           = len( nmbList )
          reverseList = list()
  
          # reverse the list
          for x in nmbList:
              reverseList.append( nmbList[i-1] )
              i -= 1
  
          # join list items to one number &amp; cast it to integer
          return int(''.join(reverseList))
  
  
      # Figure out if numbers are palindrome
      def isPalindrome( number ):
          return number == flipNumber( number )
  
      def multiplyRun(  ):
          for i in range( 100, 999 ):
              for y in range( 100, 999 ):
                  if isPalindrome( i * y ):
                      maxPalind = i * y
  
          return maxPalind
  
      # simple tests
      # print( flipNumber( 90819 ) )
      # print( isPalindrum( 9009, 9009 ) )
      # print( isPalindrum( 9109, 9009 ) )
      # print( isPalindrum( 9009, 9019 ) )
      # print( isPalindrum( 9019, 9019 ) )
      # print( isPalindrum( 9119, 9119 ) )
  
      print(multiplyRun(  ))
  </code></pre>
  
  <p>If I change the second 100 to 600 (or higher) in the second for loop, I get the correct result. It's mind boggling really, as these nested loops should go over all the ranges... What am I doing wrong!? (might be something really stupid that I'm not seeing..)</p>