#include <cstdio>
template<typename T>
class Logger {
public:
void d(char const TAG, T value);
};
template<typename T>
void Logger<T>::d(char const TAG, T value) {
char buffer[64];
snprintf(buffer, sizeof(buffer), "%d", value);
//__android_log_write(ANDROID_LOG_DEBUG, TAG, buffer);
printf("%d", buffer);
}
int main() {
auto logger = new Logger<int>;
logger->d('k', 123312);
return 0;
}
I2luY2x1ZGUgPGNzdGRpbz4KCnRlbXBsYXRlPHR5cGVuYW1lIFQ+CmNsYXNzIExvZ2dlciB7CnB1YmxpYzoKdm9pZCBkKGNoYXIgY29uc3QgVEFHLCBUIHZhbHVlKTsKfTsKCnRlbXBsYXRlPHR5cGVuYW1lIFQ+CnZvaWQgTG9nZ2VyPFQ+OjpkKGNoYXIgY29uc3QgVEFHLCBUIHZhbHVlKSB7CgljaGFyIGJ1ZmZlcls2NF07CglzbnByaW50ZihidWZmZXIsIHNpemVvZihidWZmZXIpLCAiJWQiLCB2YWx1ZSk7CgkvL19fYW5kcm9pZF9sb2dfd3JpdGUoQU5EUk9JRF9MT0dfREVCVUcsIFRBRywgYnVmZmVyKTsKCXByaW50ZigiJWQiLCBidWZmZXIpOwp9CgppbnQgbWFpbigpIHsKCWF1dG8gbG9nZ2VyID0gbmV3IExvZ2dlcjxpbnQ+OwoJbG9nZ2VyLT5kKCdrJywgMTIzMzEyKTsKCXJldHVybiAwOwp9