提交记录 5192
| 提交时间 |
评测时间 |
| 2018-08-11 10:31:06 |
2020-08-01 00:13:42 |
#include <stdio.h>
template <size_t _I_Buffer_Size = 1 << 23, size_t _O_Buffer_Size = 1 << 23>
struct IO_Tp {
char _I_Buffer[_I_Buffer_Size],*_I_pos,_O_Buffer[_O_Buffer_Size],*_O_pos;
IO_Tp(): _I_pos(_I_Buffer), _O_pos(_O_Buffer){fread(_I_Buffer, 1, _I_Buffer_Size, stdin);}
~IO_Tp() { fwrite(_O_Buffer, 1, _O_pos - _O_Buffer, stdout); }
inline bool is_digit(const char ch) { return '0'<=ch&&ch<='9';}
template <typename Int> inline IO_Tp& operator>>(Int& res)
{
res = 0;
int k = 1;
while (!is_digit(*_I_pos)){if (*_I_pos == '-')k = -1;_I_pos++;}
do (res = (res << 3) + (res << 1)) += (*_I_pos++) & 15;while (is_digit(*_I_pos));
res = (k == -1 ? -res : res);
return *this;
}
inline char getop(){while (!is_digit(*_I_pos))_I_pos++;return (*_I_pos++) & 15;}
template <typename Int> inline IO_Tp& operator<<(Int n)
{
if (n < 0) {*_O_pos++ = '-';n = -n;}
static char _buf[20];
char* _pos(_buf);
do *_pos++ = '0' + n % 10;while (n /= 10);
while (_pos != _buf)*_O_pos++ = *--_pos;
return *this;
}
inline IO_Tp& operator<<(char ch){*_O_pos++ = ch;return *this;}
};
IO_Tp<> IO;
int main()
{
int n,a,b;
IO >> n;
while (n--) {IO >> a >> b;IO << a + b << '\n';}
return 0;
}
| Compilation | N/A | N/A | Compile OK | Score: N/A | 显示更多 |
| Testcase #1 | 16.48 us | 32 KB | Accepted | Score: 100 | 显示更多 |
Judge Duck Online | 评测鸭在线
Server Time: 2026-04-12 07:53:49 | Loaded in 0 ms | Server Status
个人娱乐项目,仅供学习交流使用 | 捐赠