You are viewing a single comment's thread. Return to all comments →
C++ solution
int squares(int a, int b) {
int count=0; if(floor(sqrt(a))==sqrt(a)) { if(a==b) return 1; count++; } count=(int)sqrt(b)-(int)sqrt(a)+count; return count;
}
Seems like cookies are disabled on this browser, please enable them to open this website
Sherlock and Squares
You are viewing a single comment's thread. Return to all comments →
C++ solution
int squares(int a, int b) {
}