Reverse digits of an integer. Example1: x =
123, return 321 Example2: x = -123, return –321 这道题应该不用详细说了。比较简单。唯一的是要注意特殊值0.
public class Solution { publ...
分类:
其他好文 时间:
2014-05-24 01:39:59
阅读次数:
170
1 For循环
语法:begin
for i in reverse 1..10 loop
insert into users values(i,’奥巴马‘);
end loop;
end;
注意:循环变量 i 是隐含增加的,所以无法看到
2 goto语句...
分类:
数据库 时间:
2014-05-22 12:12:34
阅读次数:
335
integer to String :int i = 42;String str =
Integer.toString(i);orString str = "" + i double to String :String str =
Doubl...
分类:
编程语言 时间:
2014-05-20 12:54:45
阅读次数:
358
工具用 SQLite
Dev数据类型:1.NULL:空值。2.INTEGER:带符号的整型,具体取决有存入数字的范围大小。3.REAL:浮点数字,存储为8-byte
IEEE浮点数。4.TEXT:字符串文本。5.BLOB:二进制对象。=======================添加 sqlite-...
分类:
数据库 时间:
2014-05-19 17:09:21
阅读次数:
349
题目链接 You are given two linked lists representing
two non-negative numbers. The digits are stored in reverse order and each of
their nodes contain a si...
分类:
其他好文 时间:
2014-05-19 13:53:32
阅读次数:
296
You are given two linked lists representing two
non-negative numbers. The digits are stored in reverse order and each of their
nodes contain a single ...
分类:
其他好文 时间:
2014-05-19 12:05:23
阅读次数:
386
Leetcode 151题 Reverse Words in a String...
分类:
其他好文 时间:
2014-05-18 10:51:21
阅读次数:
243
【题目】
Given a linked list, reverse the nodes of a linked list k at a time and return its modified list.
If the number of nodes is not a multiple of k then left-out nodes in the end should remain as it is.
You may not alter the values in the nodes, only n...
分类:
其他好文 时间:
2014-05-18 10:22:34
阅读次数:
367
【题目】
Given a roman numeral, convert it to an integer.
Input is guaranteed to be within the range from 1 to 3999.
【题意】
把罗马数转换为整数
【思路】
罗马数字中只使用如下七个基值字母:M,D,C,L,X,V,I,分别用来表示1000、500、100、50、10、5、1。
大体思路是每个罗马字母对应的值相加即可,
但需要处理900, 400, 90, 40, 9, 4这几个特殊...
分类:
其他好文 时间:
2014-05-18 07:58:54
阅读次数:
293
题目:
Given an input string, reverse the string word by word.
For example,
Given s = "the sky is blue",
return "blue is sky the".
Clarification:
What constitutes a word?
A sequence of non-spa...
分类:
其他好文 时间:
2014-05-18 04:12:07
阅读次数:
198