title: c sum of the squares of all the coefficients in pascals triangle in random row
body: <p>So I´ve been trying to solve this problem, but I just can´t. The thing is, I put a number of row in triangle, (can be any random number/row) and the program should return the sum of the squares of all the coefficients in that row.</p>
  <pre><code>#include &lt;stdio.h&gt;
  
  unsigned long sum_triangle(const int row);
  
  int main(){
   printf(&quot;%lu\n&quot;, sum_triangle(7));
  
   // sum(7)....7 is number of row
  
  return 0;
  }
  
  unsigned long sum_triangle(const int row){
  unsigned long sum = 0;
  int temp =0;
  for (int line = 0; line &lt;= row ; line++) {
      for (int number = 0; number &lt;= line ; number++){
          if (line == row){
              temp = THIS NEEDS TO BE COMBINED SOMEHOW(line , number);
              sum += (temp * temp);
          }
      }
   }
  return sum;
  }
  </code></pre>
  <p>Problem is in the &quot;temp&quot;. I need to somehow combine row and number and thats it. Any help would be much appreciated.</p>