码迷,mamicode.com
首页 >  
搜索关键字:integer    ( 14932个结果)
【LeetCode】String to Integer (atoi) 解题报告 (Java)
这道题在LeetCode OJ上难道属于Easy,但是通过率却比较低,究其原因是需要考虑的情况比较低,很少有人一遍过吧。 【题目】 Implement atoi to convert a string to an integer. Hint: Carefully consider all possible input cases. If you want a challenge,...
分类:编程语言   时间:2014-10-27 17:47:03    阅读次数:276
Lowest Bit
Problem DescriptionGiven an positive integer A (1 2 #include 3 4 5 int main(){ 6 int A; 7 int timer; 8 9 while(1){10 t...
分类:其他好文   时间:2014-10-27 17:32:52    阅读次数:143
String to Integer (atoi)
Question:Implementatoito convert a string to an integer.Hint:Carefully consider all possible input cases. If you want a challenge, please do not see b...
分类:其他好文   时间:2014-10-27 12:25:57    阅读次数:121
[Leetcode] Integer to Roman
Given an integer, convert it to a roman numeral.Input is guaranteed to be within the range from 1 to 3999.Solution: 1 public class Solution { 2 pu...
分类:其他好文   时间:2014-10-27 01:47:12    阅读次数:139
leetcode第40题--First Missing Positive
题目:Given an unsorted integer array, find the first missing positive integer.For example,Given[1,2,0]return3,and[3,4,-1,1]return2.Your algorithm should...
分类:其他好文   时间:2014-10-26 22:37:58    阅读次数:196
poj 1503 Integer Inquiry
题目链接:http://poj.org/problem?id=1503思路: 基本的高精度问题,使用字符数组存储然后处理即可。代码:#include #include using namespace std;const int M = 100 + 10;char input[M];int A[M],...
分类:其他好文   时间:2014-10-26 18:24:13    阅读次数:116
一种GetTickCount64实现
unit?uGetTickCount64; interface uses?windows; ?function?_GetTickCount64():?Int64; implementation type ????LARGE_INTEGER?=?record ??????lowpart??:integer?; ??????highpart?...
分类:其他好文   时间:2014-10-26 17:08:25    阅读次数:407
[Leetcode] Palindrome Number
Determine whether an integer is a palindrome. Do this without extra space.click to show spoilers.Some hints:Could negative integers be palindromes? (i...
分类:其他好文   时间:2014-10-26 16:52:38    阅读次数:148
leetcode - First Missing Positive
Given an unsorted integer array, find the first missing positive integer. For example, Given [1,2,0] return 3, and [3,4,-1,1] return 2. Your algorithm should run in O(n) time and uses constant...
分类:其他好文   时间:2014-10-26 14:25:50    阅读次数:177
leetcode - N-Queens
The n-queens puzzle is the problem of placing n queens on an n×n chessboard such that no two queens attack each other. Given an integer n, return all distinct solutions to the n-queens puzzle. ...
分类:其他好文   时间:2014-10-26 14:23:18    阅读次数:164
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!