結果

問題 No.553 AlphaCoder Rating
ユーザー kaito_tateyamakaito_tateyama
提出日時 2017-08-11 23:25:36
言語 C++14
(gcc 12.3.0 + boost 1.83.0)
結果
WA  
実行時間 -
コード長 833 bytes
コンパイル時間 715 ms
コンパイル使用メモリ 77,448 KB
実行使用メモリ 5,376 KB
最終ジャッジ日時 2024-04-20 23:39:54
合計ジャッジ時間 1,399 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 WA -
testcase_08 WA -
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <fstream>
#include <vector>
#include <string>
#include <algorithm>
#include <stdio.h>
#include <math.h>
using namespace std;

double F(int n){
  double a = pow(100, n) - pow(81, n);
  double b = pow(10, n) - pow(9, n);
  double c = sqrt(a) / (sqrt(19) * b);
  return c;
}

double f(int n){
  double a = F(n) - (1 / sqrt(19));
  double b = 1 - (1 / sqrt(19));
  double c = (1200 * a) / b;
  return c;
}
double g(int x){
  double a = pow(2,x / 800);
  return a;
}

double g1(double x){
  double a = (800 * log(x)) / log(2);
  return a;
}

int main(){

  cout << f(1);
  int n; cin >> n;
  double sum = 0;
  for (int i = 1; i <= n; i++) {
    int a; cin >> a;
    sum += pow(0.9, i) * g(a);
  }
  double m = sum / (9 * (1-pow(0.9, n)));
  int rating = g1(m) - f(n);
  cout << rating << "\n";

  return 0;
}
0