結果
問題 |
No.863 計算量
|
ユーザー |
![]() |
提出日時 | 2019-08-21 05:57:10 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 2 ms / 1,000 ms |
コード長 | 701 bytes |
コンパイル時間 | 2,166 ms |
コンパイル使用メモリ | 210,428 KB |
最終ジャッジ日時 | 2025-01-07 14:28:40 |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 13 |
コンパイルメッセージ
main.cpp: In function ‘void rd(double&)’: main.cpp:5:8: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 5 | scanf("%lf",&x); | ~~~~~^~~~~~~~~~
ソースコード
#pragma GCC optimize ("Ofast") #include<bits/stdc++.h> using namespace std; inline void rd(double &x){ scanf("%lf",&x); } inline void wt_L(char a){ putchar_unlocked(a); } inline void wt_L(int x){ char f[10]; int m=0, s=0; if(x<0){ m=1; x=-x; } while(x){ f[s++]=x%10; x/=10; } if(!s){ f[s++]=0; } if(m){ putchar_unlocked('-'); } while(s--){ putchar_unlocked(f[s]+'0'); } } int main(){ double A, B; rd(A); rd(B); if(B/A < 80){ wt_L(1); wt_L('\n'); } else{ wt_L(2); wt_L('\n'); } return 0; } // cLay varsion 20190820-1 // --- original code --- // { // double A, B; // rd(A,B); // wt(if[B/A < 80, 1, 2]); // }