QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#165471#7102. Live LoveikunsomeCompile Error//C++23328b2023-09-05 18:30:242023-09-05 18:30:25

Judging History

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

  • [2023-09-05 18:30:25]
  • 评测
  • [2023-09-05 18:30:24]
  • 提交

answer

#include <iostream>#include <iostream>
using namespace std;
int main() {
    int t;cin>>t;
    while(t--){
        int n,m;cin>>n>>m;
        cout<<(m,n/(n-m+1))<<'\n';
    }
}

using namespace std;
int main() {
    int t;cin>>t;
    while(t--){
        int n,m;cin>>n>>m;
        cout<<(m,n/(n-m+1));
    }
}

Details

answer.code:1:20: warning: extra tokens at end of #include directive
    1 | #include <iostream>#include <iostream>
      |                    ^
answer.code:12:5: error: redefinition of ‘int main()’
   12 | int main() {
      |     ^~~~
answer.code:3:5: note: ‘int main()’ previously defined here
    3 | int main() {
      |     ^~~~