結果

問題 No.280 歯車の問題(1)
コンテスト
ユーザー naimonon77
提出日時 2015-11-12 20:56:53
言語 C++11
(gcc 15.2.0 + boost 1.89.0)
コンパイル:
g++-15 -O2 -lm -std=gnu++11 -Wuninitialized -DONLINE_JUDGE -o a.out _filename_
実行:
./a.out
結果
RE  
実行時間 -
コード長 700 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 316 ms
コンパイル使用メモリ 50,284 KB
実行使用メモリ 6,400 KB
最終ジャッジ日時 2026-04-04 05:48:28
合計ジャッジ時間 7,597 ms
ジャッジサーバーID
(参考情報)
judge3_1 / judge5_1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other RE * 31
権限があれば一括ダウンロードができます
コンパイルメッセージ
main.cpp: In function 'int main()':
main.cpp:36:19: warning: 'end' may be used uninitialized [-Wmaybe-uninitialized]
   36 |   rep(i,n-1) scanf("%llu",end);
      |              ~~~~~^~~~~~~~~~~~
main.cpp:33:13: note: 'end' was declared here
   33 |   ull start,end;
      |             ^~~

ソースコード

diff #
raw source code

#include <cstring>
#include <algorithm>
#include <cstdio>
#include <ctype.h>
#include <limits.h>
#define REP(i,a,b) for(i=a;i<b;i++)
#define rep(i,n) REP(i,0,n)

using namespace std;

typedef long long ll;
typedef unsigned long long ull;
typedef long double ld;
/* ここからが本編 */
/* */
/* 入力開始! */
/* 入力終了! */
/* ll_pow(x,n)はx^nを返すよ! */
ll ll_pow(ll x,ll n) {
   ll res = 1;
   while(n > 0) {
      if(n&1) res = res * x;
      x = x * x;
      n >>= 1;
   }
   return res;
}

int main(void)
{
  int i,j;
  int n;
  ull start,end;
  scanf("%d",&n);
  scanf("%llu",&start);
  rep(i,n-1) scanf("%llu",end);
  printf("%llu/%llu",end/start);
  
  
  return 0;
}
0