結果

問題 No.237 作図可能性
ユーザー koba-e964
提出日時 2015-07-06 12:43:46
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
AC  
実行時間 2 ms / 2,000 ms
コード長 318 bytes
コンパイル時間 1,302 ms
コンパイル使用メモリ 163,464 KB
実行使用メモリ 5,376 KB
最終ジャッジ日時 2024-07-08 01:19:52
合計ジャッジ時間 2,227 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 28
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define rep(i,n) for(int i=0;i<(int)(n);i++)

set<ll> se;
ll p[5]={3,5,17,257,65537};
int main(){
 ll n;cin>>n;
 rep(b, 32) {
ll s =1;
rep(i,5)s *= b&(1<<i)?p[i]:1;
  rep(i, 30) {
ll w=s<<i;
if(w<=n&&3<=w)se.insert(w);
  }
 }
cout<<se.size()<<endl;
}
0