当arg为5.000时,用%f输出5.000,想输出5用%g,如下:
[NSString stringWithFormat:@"%@:%g, %@:%g", L(@"STR_ID_TOPIC"), dto.topicCount, L(@"STR_ID_REPLY_NUM"), dto.replyCount]
时间: 2024-11-13 08:06:19
当arg为5.000时,用%f输出5.000,想输出5用%g,如下:
[NSString stringWithFormat:@"%@:%g, %@:%g", L(@"STR_ID_TOPIC"), dto.topicCount, L(@"STR_ID_REPLY_NUM"), dto.replyCount]