for(int i =1; i <65; i++) {printf("Current count is: %d\nCurrent total is: %llu\n", i, total); total +=square(i);}
While loop
Get number of digits in an int, then use the length to assign the memory for the char array
//Identify the number of digits in a numbernDigits =floor(log10(abs(num))) +1;printf("Number of digits is %d\n\n",nDigits);total =0;//assign an array based on the number of digitschar Digits[nDigits];//assign number as string in char pointersprintf((char*)Digits,"%u",num);