赛时95,现在15
查看原帖
赛时95,现在15
1444655
gaoxijun20140828楼主2025/6/30 12:53
#include<bits/stdc++.h>
using namespace std;
int main(){
    int n,m,t=0;cin>>n>>m;
    for(int i=n;i<=m;i++){
        for(int x=0;x<=sqrt(n);x++){
            for(int y=0;y<=sqrt(m);y++){
                if(pow(2,x)+pow(2,y)==i){
                    t++;
                }
            }
        }
    }
    cout<<t;
}
2025/6/30 12:53
加载中...