Strings are constant; their values cannot be changed after they are created String s1 = "Hello";String s2 = "Hello";System.out.println(s1==s2); //true...
分类:
其他好文 时间:
2014-09-20 17:16:59
阅读次数:
185
字符串和字符(Strings and Characters)本页包含内容:字符串字面量初始化空字符串字符串可变性字符串是值类型使用字符计算字符数量连接字符串和字符字符串插值比较字符串字符串大小写UnicodeString是例如“hello, world”,“海贼王” 这样的有序的Character(...
分类:
其他好文 时间:
2014-09-20 01:08:36
阅读次数:
256
Palindrome Partitioning IIGiven a strings, partitionssuch that every substring of the partition is a palindrome.Return the minimum cuts needed for a p...
分类:
其他好文 时间:
2014-09-19 22:21:56
阅读次数:
261
1.1. 问题 ProblemYou need to deal with data that doesn't fit in the ASCII character set. 你需要处理不适合用ASCII字符集表示的数据. 1.2. 解决 SolutionUnicode strings can be ...
分类:
编程语言 时间:
2014-09-18 16:17:14
阅读次数:
286
Binary String Matching
时间限制:3000 ms | 内存限制:65535 KB
难度:3
描述
Given two strings A and B, whose alphabet consist only ‘0’ and ‘1’. Your task is only to tell how many times does A appear as ...
分类:
其他好文 时间:
2014-09-18 11:34:53
阅读次数:
178
1、标准库string类型:用户程序要使用string类型对象,必须包含相关头文件#include字符串字面值与标准库string类型不是同一种类型,字符串字面值是字符数组,而string是对象2、intmain(){strings;cin>>s;cout>s) result+=s;cout=[]其...
分类:
编程语言 时间:
2014-09-17 02:15:51
阅读次数:
423
题目:https://oj.leetcode.com/problems/add-binary/Given two binary strings, return their sum (also a binary string).For example,a = "11"b = "1"Return "10...
分类:
编程语言 时间:
2014-09-16 10:31:00
阅读次数:
174
现象描述: android项目,使用eclipse打apk包时,报错: strings.xml等资源文件***is not translated in zh 解决方法: 项目树选中鼠标右键?-?Properties?-?Android?Lint?preferences?-?MissingTranslat...
分类:
移动开发 时间:
2014-09-14 20:50:18
阅读次数:
224
二进制字符创相加,通过进位的方式逐位考虑。也可以把相加的过程抽象成一个函数。
Given two binary strings, return their sum (also a binary string).
For example,
a = "11"
b = "1"
Return "100".
方法一:
class Solution {
public:
s...
分类:
其他好文 时间:
2014-09-14 15:26:07
阅读次数:
285
Given a stringS, find the longest palindromic substring inS. You may assume that the maximum length ofSis 1000, and there exists one unique longest pa...
分类:
其他好文 时间:
2014-09-14 12:49:37
阅读次数:
214