QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#297655#5733. SpeedingjparkWA 1ms3716kbC++14330b2024-01-04 21:46:022024-01-04 21:46:04

Judging History

你现在查看的是最新测评结果

  • [2024-01-04 21:46:04]
  • 评测
  • 测评结果:WA
  • 用时:1ms
  • 内存:3716kb
  • [2024-01-04 21:46:02]
  • 提交

answer

#include<iostream>
using namespace std;

int main(){
    double maxs = 0;
    int n; cin >> n;
    double prevt, prevd; cin >> prevt >> prevd;
    for(int i=1; i<n; ++i){
        double a,b; cin >> a >> b;
        maxs = max(maxs, (b-prevd)/(a-prevt));
        prevt = a;
        prevd = b;
    }
    cout << maxs;
}

詳細信息

Test #1:

score: 100
Accepted
time: 1ms
memory: 3616kb

input:

2
0 0
7 42

output:

6

result:

ok single line: '6'

Test #2:

score: -100
Wrong Answer
time: 1ms
memory: 3716kb

input:

5
0 0
5 24
10 98
15 222
20 396

output:

34.8

result:

wrong answer 1st lines differ - expected: '34', found: '34.8'