码迷,mamicode.com
首页 > 其他好文 > 详细

1115 视频的阅读数目 更改

时间:2016-11-15 11:07:36      阅读:135      评论:0      收藏:0      [点我收藏+]

标签:margin   news   lis   阅读   ring   class   1.0   with   int   

        NSString *readStr=[NSString stringWithFormat:@"%@", [newsLIST objectForKey:@"readnum"]];

        NSString  *readDa = readStr;

        if (readStr.length>=5) {

            NSInteger redNum = [readStr integerValue];

            NSString  *one,*two;

            NSInteger  onee = redNum/10000;

            one = [NSString stringWithFormat:@"%zd",onee];

            

            NSInteger  twoo = redNum%10000;

            twoo = twoo/1000;

            two = [NSString stringWithFormat:@"%zd",twoo];

            if (one.length>1) {

                readDa=[NSString stringWithFormat:@"%@",one];

  

            }else{

                readDa=[NSString stringWithFormat:@"%@.%@",one,two];

 

            

            }

            

        }else{

            readDa=[NSString stringWithFormat:@"%@", [newsLIST objectForKey:@"readnum"]];

            

        }

        

1115 视频的阅读数目 更改

标签:margin   news   lis   阅读   ring   class   1.0   with   int   

原文地址:http://www.cnblogs.com/gzz2016/p/6064490.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!