题解 | 平方根
平方根
https://www.nowcoder.com/practice/cd21e09482f24b03842f02ae3d403cad
#include <iostream>
#include <cmath>
using namespace std;
int main() {
int a;
cin>>a;
double c= sqrt(a);
cout<<floor(c);
}
// 64 位输出请用 printf("%lld")
平方根
https://www.nowcoder.com/practice/cd21e09482f24b03842f02ae3d403cad
#include <iostream>
#include <cmath>
using namespace std;
int main() {
int a;
cin>>a;
double c= sqrt(a);
cout<<floor(c);
}
// 64 位输出请用 printf("%lld")
相关推荐