Created
          December 12, 2020 07:19 
        
      - 
      
- 
        Save sparrowhe/df7c1a16362faa06f9f8f8d2d7c064e9 to your computer and use it in GitHub Desktop. 
    CCF Arbiter评测机 自动AC机
  
        
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | /* | |
| * CCF Arbiter Auto AC Hacker | |
| * Sat Dec 12 2020 15:09:44 GMT+0800 (中国标准时间) | |
| * Author: Anonymous | |
| * Don't use it in CCF's competition | |
| */ | |
| #include<iostream> | |
| #include<cstdio> | |
| #include<string> | |
| #include<cstring> | |
| #include <fstream> | |
| #define MAX_TEST 2 | |
| using namespace std; | |
| bool cmp(string a, string b) { | |
| FILE * f1, * f2; | |
| f1 = fopen(a.c_str(), "r"); | |
| f2 = fopen(b.c_str(), "r"); | |
| char ch1,ch2; | |
| do { | |
| ch1 = fgetc(f1); | |
| ch2 = fgetc(f2); | |
| if (ch1 != ch2) { | |
| return false; | |
| } | |
| } while (ch1 != EOF || ch2 != EOF); | |
| return true; | |
| } | |
| int main() { | |
| freopen("test.out","w",stdin); | |
| for(int i = 1; i <= MAX_TEST; i++) { | |
| string num; | |
| stringstream aaa; | |
| aaa << i; | |
| aaa >> num; | |
| if(cmp("../evaldata/test"+num+".in","test.in")){ | |
| //cout << i; | |
| FILE* f1; | |
| f1 = fopen(("../evaldata/test"+num+".ans").c_str(), "r"); | |
| char ch1; | |
| do { | |
| ch1 = fgetc(f1); | |
| if(ch1 == EOF) { | |
| break; | |
| } | |
| cout << ch1; | |
| } while (ch1 != EOF); | |
| break; | |
| } | |
| } | |
| return 0; | |
| } | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment