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

【Leetcode】整数反转

时间:2019-08-06 00:34:33      阅读:75      评论:0      收藏:0      [点我收藏+]

标签:log   shu   反转   etc   solution   int   integer   题解   时间复杂度   

技术图片

 

题解参考:https://leetcode-cn.com/problems/reverse-integer/solution/zheng-shu-fan-zhuan-by-leetcode/

 

技术图片

技术图片

 技术图片

复杂度分析

时间复杂度:O(log(x)),x中大约有 log10(x) 位数字。
空间复杂度:O(1)。

 

【Leetcode】整数反转

标签:log   shu   反转   etc   solution   int   integer   题解   时间复杂度   

原文地址:https://www.cnblogs.com/gdut-gordon/p/11306354.html

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