title: Calculate number of perfect squares in a given big range in C
body: <p>I already have the code where I calculate the number of perfect squares between 1 and a max range:</p>
  
  <pre><code>int perfectCounter = 0;
  int i = 1;
  int maxRange;
  
  scanf("%d", &amp;maxRange);
  
  while (i &lt;= maxRange) {
     float tempSquare = sqrt(i);
     int integerPart = tempSquare;
  
     if (tempSquare == integerPart)
        perfectCounter++;
  }
  </code></pre>
  
  <p>Problem is, that max range must be between 1 and 10^1000, so I can't store that maxRange on a int, long or long double. I can't think on a solution for that, without using external libraries that handle very big numbers.</p>