登录
|
注册
公司
标签
文章
搜索
字符串
热门公司
百度
微软
腾讯
华为
阿里巴巴
迅雷
热门职位
C语言工程师
研发工程师
测试工程师
所有
有回答
没回答
新题目
有最佳答案
排序
热度
·
时间
·
经典指数
0
0
1623
Given a string s consists of upper/lower-case alphabets and empty space characters' ', return the length of last word in the string. If the last word does not exist, return 0. Note: A word is defined as a character sequence consists of non-space characters only. For example, Given s ="Hello World", return5. ...
阅读题目
C语言工程师
字符串
面试题
经典指数
0
0
4548
String str = new String(“abc”),“abc”在内存中是怎么分配的? 堆 栈 字符串常量区 寄存器 ...
阅读题目
Java
人人网
操作系统
字符串
多选题
经典指数
0
0
1053
Given an array of words and a length L, format the text such that each line has exactly L characters and is fully (left and right) justified. You should pack your words in a greedy approach; that is, pack as many words as you can in each line. Pad extra spaces' 'when necessary so that each line has exactly L characters. Extra spaces between words should be distributed as evenly as possible. If the number of spaces on a line do not divide evenly between words, the empty slots on the left wi ...
阅读题目
字符串
面试题
经典指数
0
0
1163
Given a string, find the length of the longest substring without repeating characters. For example, the longest substring without repeating letters for "abcabcbb" is "abc", which the length is 3. For "bbbbb" the longest substring is "b", with the length of 1. ...
阅读题目
字符串
面试题
经典指数
0
0
954
Given an array of strings, return all groups of strings that are anagrams. Note: All inputs will be in lower-case. ...
阅读题目
字符串
面试题
经典指数
0
0
1542
注意:请尽可能详细描述你的数据结构、系统架构、设计思路等。建议多写一些伪代码或者流程说明。 1. 考虑一个字符串替换的过程,在一个文本文件中含有一些文本内容和一些需要替换的变量,变量的格式为“$Var$”,原来的“$”使用“$$”进行转义,原来的“$$”表示为“$$$”。我们将含有变量的文件称为模板(文件名为t),文本文件的平均长度为100K。另外,还有一系列的变量文件,里面为变量名和变量值的对应关系(文件名为1.v , 2.v… n.v),每个变量文件包含的变量数在百万数量级,且变量排列次序不定。现要求将,模板里的变量分别用变量文件里的变量替换,并将生成的文件写成 (1.r, 2.r… n.r)。 要求:从算法和实现上和实现技术上的细节对程序进行优化,尽量使程序高效。程序运行环境为2G内存,4CPU。阐明主要思路,给出伪码和说明,可以着重指出你使用的优化技术。 例子:模板文件为 This is an $FF$ $$. I like $FF$ and $FA$。 变量文件为 1.v FF : banana FA : apple 2.v F ...
阅读题目
百度
字符串
问答题
经典指数
0
0
1538
Given a string S and a string T, count the number of distinct subsequences of T in S. A subsequence of a string is a new string which is formed from the original string by deleting some (can be none) of the characters without disturbing the relative positions of the remaining characters. (ie,"ACE"is a subsequence of"ABCDE"while"AEC"is not). Here is an example: S ="rabbbit", T ="rabbit" Return3. ...
阅读题目
动态规划
字符串
面试题
经典指数
0
0
1616
在字符串S中寻找最长的字符串x,条件是x存在于S中。即是如:abcabcdcd中的abc。 ...
阅读题目
网易
字符串
问答题
经典指数
0
0
1344
Given a string, you are supposed to output the length of the longest symmetric sub-string. For example, given "Is PAT&TAP symmetric?", the longest symmetric sub-string is "s PAT&TAP s", hence you must output 11. 输入描述: Each input file contains one test case which gives a non-empty string of length no more than 1000. 输出描述: For each test case, simply print the maximum length in a line. 输入例子: Is PAT&TAP symmetric? 输出例子: 11 ...
阅读题目
动态规划
字符串
面试题
经典指数
0
0
1421
remove掉给定字符串中的多余空格,要求达到以下要求 A.无连续相邻的两个空格 B.字符串开头和结尾无空格 C.新的一行开头和结尾无空格 ...
阅读题目
微软
字符串
问答题
经典指数
1
2
3
4
32
题目数
1
贡献者
212
答案数
扫描后移动端查看
我也分享一个题目
相关标签
C语言工程师
百度
查找
复杂度
研发工程师
动态规划
微软
基础知识
腾讯
华为
同类标签
树
排序
数组
链表
复杂度
查找
栈
图
哈希
队列
微信公众号
欢迎加入,一起群聊
×
登录
注册
找回密码
记住登录
登录
快速注册
直接第三方登录