QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#619585#2442. Welcome PartyIllusionaryDominance#Compile Error//C++202.8kb2024-10-07 14:42:442024-10-07 14:42:48

Judging History

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

  • [2024-10-07 14:42:48]
  • 评测
  • [2024-10-07 14:42:44]
  • 提交

answer

#define Please return
#define AC 0
#define cin Mizuhashi
#define cout Parsee
#define endl '\n'

class Reader{
	private:
	    static const int BUF_SIZE = 1 << 22;
	    char BUF_R[BUF_SIZE], *csy1, *csy2;
	    #ifndef _LOCAL_RUNNING
		    #define GC (csy1 == csy2 && (csy2 = (csy1 = BUF_R) + fread(BUF_R, 1, BUF_SIZE, stdin), csy1 == csy2) ? EOF : *csy1 ++)
		#else
		    char cur;
		    #define GC (cur = getchar())
		#endif
	    #define IL inline
		
    public:
        IL bool eof() {
            #ifndef _LOCAL_RUNNING
                return csy1 == csy2 && (csy2 = (csy1 = BUF_R) + fread(BUF_R, 1, BUF_SIZE, stdin), csy1 == csy2);
            #else
                return cur == EOF;
            #endif
        }
        template <class Ty>
        IL Reader& operator >> (Ty &t) {
            int u = 0;
            char c = GC;
	    	for (t = 0; c < 48 || c > 57; c = GC)
                if (c == EOF) break;
                else if (c == '-') u = 1;
	    	for ( ; c > 47 && c < 58; c = GC) t = t * 10 + (c ^ 48);
	    	t = u ? -t : t; return *this;
        }
    	IL Reader& operator >> (double &t) {
            int tmp, u = 0; char c = GC;
	    	for (tmp = 0; c < 48 || c > 57; c = GC)
                if (c == EOF) break;
                else if (c == '-') u = 1;
	    	for ( ; c > 47 && c < 58; c = GC) tmp = tmp * 10 + (c ^ 48);
	    	t = (tmp = u ? -tmp : tmp);
    	    if (c == '.') {
    	        double x = 1;
    	        for (c = GC; c > 47 && c < 58; c = GC) t += (x /= 10) * (c ^ 48);
    	    }
    	    return *this;
    	}
    	IL Reader& operator >> (char *s) {
			char c = GC;
			for (*s = 0; c < 33; c = GC) if (c == EOF) return *this;
			for ( ; c > 32; c = GC) *s ++ = c;
			*s = 0; return *this;
		}
        IL Reader& operator >> (char &c) {
			for (c = GC; c < 33; c = GC) if (c == EOF) return *this;
            return *this;
        }
}cin;
class Writer{
	private:
	    static const int BUF_SIZE = 1 << 22;
	    char BUF_W[BUF_SIZE], *csy;
	    #define IL inline
		inline void WC(const char c) {
			if (csy - BUF_W == BUF_SIZE) fwrite(BUF_W, 1, BUF_SIZE, stdout), csy = BUF_W;
			*csy ++ = c;
		}
	
	public:
		Writer() : csy(BUF_W) {}
		~ Writer() {fwrite(BUF_W, 1, csy - BUF_W, stdout);}
		IL void flush() {fwrite(BUF_W, 1, csy - BUF_W, stdout); csy = BUF_W;}
		template <class Ty>
		IL Writer& operator << (Ty x) {
		    static int sta[32], top;
			if (x < 0) {
				WC('-');
                do sta[top ++] = - (x % 10); while (x /= 10);
			}else do sta[top ++] = x % 10; while (x /= 10);
			while (top) WC(sta[-- top] ^ 48);
			return *this;
		}
		IL Writer& operator << (const char &c) {WC(c); return *this;}
		IL Writer& operator << (const char *s) {while (*s) WC(*s ++); return *this;}
}cout;

using namespace std;

详细

answer.code: In member function ‘bool Reader::eof()’:
answer.code:22:91: error: ‘stdin’ was not declared in this scope
   22 |                 return csy1 == csy2 && (csy2 = (csy1 = BUF_R) + fread(BUF_R, 1, BUF_SIZE, stdin), csy1 == csy2);
      |                                                                                           ^~~~~
answer.code:1:1: note: ‘stdin’ is defined in header ‘<cstdio>’; did you forget to ‘#include <cstdio>’?
  +++ |+#include <cstdio>
    1 | #define Please return
answer.code:22:65: error: ‘fread’ was not declared in this scope; did you mean ‘friend’?
   22 |                 return csy1 == csy2 && (csy2 = (csy1 = BUF_R) + fread(BUF_R, 1, BUF_SIZE, stdin), csy1 == csy2);
      |                                                                 ^~~~~
      |                                                                 friend
answer.code: In member function ‘Reader& Reader::operator>>(Ty&)’:
answer.code:12:100: error: ‘stdin’ was not declared in this scope
   12 |                     #define GC (csy1 == csy2 && (csy2 = (csy1 = BUF_R) + fread(BUF_R, 1, BUF_SIZE, stdin), csy1 == csy2) ? EOF : *csy1 ++)
      |                                                                                                    ^~~~~
answer.code:30:22: note: in expansion of macro ‘GC’
   30 |             char c = GC;
      |                      ^~
answer.code:12:100: note: ‘stdin’ is defined in header ‘<cstdio>’; did you forget to ‘#include <cstdio>’?
   12 |                     #define GC (csy1 == csy2 && (csy2 = (csy1 = BUF_R) + fread(BUF_R, 1, BUF_SIZE, stdin), csy1 == csy2) ? EOF : *csy1 ++)
      |                                                                                                    ^~~~~
answer.code:30:22: note: in expansion of macro ‘GC’
   30 |             char c = GC;
      |                      ^~
answer.code:12:74: error: there are no arguments to ‘fread’ that depend on a template parameter, so a declaration of ‘fread’ must be available [-fpermissive]
   12 |                     #define GC (csy1 == csy2 && (csy2 = (csy1 = BUF_R) + fread(BUF_R, 1, BUF_SIZE, stdin), csy1 == csy2) ? EOF : *csy1 ++)
      |                                                                          ^~~~~
answer.code:30:22: note: in expansion of macro ‘GC’
   30 |             char c = GC;
      |                      ^~
answer.code:12:74: note: (if you use ‘-fpermissive’, G++ will accept your code, but allowing the use of an undeclared name is deprecated)
   12 |                     #define GC (csy1 == csy2 && (csy2 = (csy1 = BUF_R) + fread(BUF_R, 1, BUF_SIZE, stdin), csy1 == csy2) ? EOF : *csy1 ++)
      |                                                                          ^~~~~
answer.code:30:22: note: in expansion of macro ‘GC’
   30 |             char c = GC;
      |                      ^~
answer.code:12:124: error: ‘EOF’ was not declared in this scope
   12 |                     #define GC (csy1 == csy2 && (csy2 = (csy1 = BUF_R) + fread(BUF_R, 1, BUF_SIZE, stdin), csy1 == csy2) ? EOF : *csy1 ++)
      |                                                                                                                            ^~~
answer.code:30:22: note: in expansion of macro ‘GC’
   30 |             char c = GC;
      |                      ^~
answer.code:12:124: note: ‘EOF’ is defined in header ‘<cstdio>’; did you forget to ‘#include <cstdio>’?
   12 |                     #define GC (csy1 == csy2 && (csy2 = (csy1 = BUF_R) + fread(BUF_R, 1, BUF_SIZE, stdin), csy1 == csy2) ? EOF : *csy1 ++)
      |                                                                                                                            ^~~
answer.code:30:22: note: in expansion of macro ‘GC’
   30 |             char c = GC;
      |                      ^~
answer.code:12:74: error: there are no arguments to ‘fread’ that depend on a template parameter, so a declaration of ‘fread’ must be available [-fpermissive]
   12 |                     #define GC (csy1 == csy2 && (csy2 = (csy1 = BUF_R) + fread(BUF_R, 1, BUF_SIZE, stdin), csy1 == csy2) ? EOF : *csy1 ++)
      |                                                                          ^~~~~
answer.code:31:51: note: in expansion of macro ‘GC’
   31 |                 for (t = 0; c < 48 || c > 57; c = GC)
      |                                                   ^~
answer.code:12:74: error: there are no arguments to ‘fread’ that depend on a template parameter, so a declaration of ‘fread’ must be available [-fpermissive]
   12 |                     #define GC (csy1 == csy2 && (csy2 = (csy1 = BUF_R) + fread(BUF_R, 1, BUF_SIZE, stdin), csy1 == csy2) ? EOF : *csy1 ++)
      |                                                                          ^~~~~
answer.code:34:47: note: in expansion of macro ‘GC’
   34 |                 for ( ; c > 47 && c < 58; c = GC) t = t * 10 + (c ^ 48);
      |                                               ^~
answer.code: In member f...