题解 | 整数的十位
整数的十位
https://www.nowcoder.com/practice/031db23916904f4fad72198fe491b47b
#include <iostream>
#include <cstdlib>
using namespace std;
int main() {
int a;
cin >> a;
int absolute = abs(a);
int tendigit = (abs(a) / 10) % 10;
cout << tendigit << endl;
return 0;
}
// 64 位输出请用 printf("%lld")
