码迷,mamicode.com
首页 >  
搜索关键字:digits    ( 2164个结果
leetcode : reverse integer
Reverse digits of an integer. Example1: x = 123, return 321Example2: x = -123, return -321 click to show spoilers. Have you thought about this? Here a ...
分类:其他好文   时间:2017-02-03 00:32:34    阅读次数:184
Numeric Type Attributes
【Numeric Type Attributes】 INT(4) specifies an INT with a display width of four digits. This optional display width may be used by applications to disp ...
分类:其他好文   时间:2017-02-01 15:37:47    阅读次数:126
Leetcode:258.Add Digits
题目: Given a non-negative integer num, repeatedly add all its digits until the result has only one digit. For example: Given num = 38, the process is l ...
分类:其他好文   时间:2017-01-25 15:26:48    阅读次数:197
Add Two Numbers Leetcode
You are given two non-empty linked lists representing two non-negative integers. The digits are stored in reverse order and each of their nodes contai ...
分类:其他好文   时间:2017-01-25 11:49:19    阅读次数:282
Leetcode 369. Plue one Linked List
Given a non-negative integer represented as non-empty a singly linked list of digits, plus one to the integer. You may assume the integer do not conta ...
分类:其他好文   时间:2017-01-23 15:30:32    阅读次数:231
Reverse Integer Leetcode
Reverse digits of an integer. Example1: x = 123, return 321Example2: x = -123, return -321 这道题要考虑反转之后overflow的问题,感觉我的写法很非主流啊。 还是用主流写法又写了一下 ...
分类:其他好文   时间:2017-01-20 09:45:38    阅读次数:219
Python大神成长之路: 第二次学习记录
数据类型 数据操作 bytes 类型 "".encode() 编码-->二进制 "".decode() 解码 判断字符串里的字符是否全为数字 "".isdigit(), Return True if all characters in S are digits 数据运算: 算数运算: + - * / ...
分类:编程语言   时间:2017-01-17 10:49:29    阅读次数:227
[LeetCode OJ]7. Reverse Integer
Reverse digits of an integer. Example1: x = 123, return 321Example2: x = -123, return -321 个人的大体思路: 先判断是整数还是负数,flag记录符号(-1或1),把数字取绝对值然后转换成字符串,字符串逆序,把字 ...
分类:其他好文   时间:2017-01-17 07:51:09    阅读次数:260
Plus One Leetcode
Given a non-negative integer represented as a non-empty array of digits, plus one to the integer. You may assume the integer do not contain any leadin ...
分类:其他好文   时间:2017-01-16 09:51:39    阅读次数:163
玲珑OJ 1083:XJT Love Digits(离线处理+哈希)
http://www.ifrog.cc/acm/problem/1083 题意:比较好懂。注意答案的x不包含ax本身,所以才输出-1。 思路:离线处理。根据x排序,然后每次更新Hash[]数组就好了。 ...
分类:其他好文   时间:2017-01-14 16:57:42    阅读次数:196
2164条   上一页 1 ... 80 81 82 83 84 ... 217 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!