Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- inline i64 nextInt()
- {
- i64 s = 1, x = 0, c = getc(stdin);
- while (c <= 32)
- c = getc(stdin);
- if (c == '-')
- s = -1, c = getc(stdin);
- while ('0' <= c && c <= '9')
- x = x * 10 + c - '0', c = getc(stdin);
- return x * s;
- }
- inline void printInt(i64 x)
- {
- if (x < 0)
- putc('-', stdout), x = -x;
- char s[20];
- i64 n = 0;
- while (x || !n)
- s[n++] = '0' + x % 10, x /= 10;
- while (n--)
- putc(s[n], stdout);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement