美文网首页
转换为万单位iOS

转换为万单位iOS

作者: VickyLanLan | 来源:发表于2021-12-09 10:19 被阅读0次
    + (NSString *)subscribeCountUnitChange:(NSInteger)count {     if (count/10000 == 0) {         return [NSString stringWithFormat:@"%ld",count];     }else{         NSInteger tenThouand = count/10000;         NSInteger thousand = count%10000/1000;         return [NSString stringWithFormat:@"%ld.%ld万",tenThouand,thousand>=5?thousand+1:thousand];     }     return @"0"; }

    相关文章

      网友评论

          本文标题:转换为万单位iOS

          本文链接:https://www.haomeiwen.com/subject/llqffrtx.html