QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#623229#5732. Even or OddoschlimgenWA 0ms3812kbC++20575b2024-10-09 10:45:132024-10-09 10:45:14

Judging History

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

  • [2024-10-09 10:45:14]
  • 评测
  • 测评结果:WA
  • 用时:0ms
  • 内存:3812kb
  • [2024-10-09 10:45:13]
  • 提交

answer

#include <iostream>
#include <string>
#include <sstream>
#include <vector>
#include <fstream>



class inputParams {
public:
  int n;

  inputParams() : n(0) {
    read();
  }

  void read() {
    std::string line;

    std::getline(std::cin, line);
    
    n = std::stoi(line);
  }
};

std::string createOutput(int n) {
  if(n % 2 == 0) {
    return "Odd";
  } else {
    return "Either";
  }
}


int main() {
  inputParams input;

  std::string output = createOutput(input.n);

  std::cout << output << std::endl;

  return 0;
}

詳細信息

Test #1:

score: 100
Accepted
time: 0ms
memory: 3556kb

input:

1

output:

Either

result:

ok single line: 'Either'

Test #2:

score: 0
Accepted
time: 0ms
memory: 3464kb

input:

2

output:

Odd

result:

ok single line: 'Odd'

Test #3:

score: 0
Accepted
time: 0ms
memory: 3812kb

input:

3

output:

Either

result:

ok single line: 'Either'

Test #4:

score: -100
Wrong Answer
time: 0ms
memory: 3592kb

input:

4

output:

Odd

result:

wrong answer 1st lines differ - expected: 'Even', found: 'Odd'