#include<bits/stdc++.h> using namespace std; int main(){ int l,r; cin>>l>>r; int cnt=0; for(int i=l;i<=r;i++){ bool a=0; for(int x=0;x<=15;x++){ for(int y=0;y<=15;y++){ if(pow(2,x)+pow(2,y)==i){ a=1; } } } if(a==1){ cnt++; } } cout<<cnt; return 0; }
Using your lizikid universal account