Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何将整数(或 NSInteger)的最后一位输出为整数?
例子:
int time = CFAbsoluteGetCurrent(); int lastDigit;
使用模数:
int lastDigit = time % 10;