C++#include <cstdio>
#ifdef _WIN32
#ifdef _WIN64
#define getchar_ _getchar_nolock
#define putchar_ _putchar_nolock
#else
#define getchar_ _getchar_nolock
#define putchar_ _putchar_nolock
#endif
#elif defined(__linux__)
#define getchar_ getchar_unlocked
#define putchar_ putchar_unlocked
#endif
int read () {
int s = 0, f = 1;
char ch = getchar_ ();
while (ch > '9' || ch < '0') {
if (ch == '-') f = -f;
ch = getchar_ ();
}
while (ch >= '0' && ch <= '9') {
s = (s << 3) + (s << 1) + (ch ^ 48);
ch = getchar_ ();
}
return s * f;
}
void write (int num) {
if (num == 0) {
putchar_ ('0');
return;
}
if (num < 0) {
putchar_ ('-');
num = -num;
}
char st[10] = {};
char *top = st;
while (num != 0) {
*(++ top) = num % 10 | 48;
num = num / 10;
}
while (top != st) {
putchar_ (*top --);
}
return;
}
signed main () {
// TODO
return 0;
}