摘要:
1、问题描述 Given a word, you need to judge whether the usage of capitals in it is right or not. We define the usage of capitals in a word to be right when 阅读全文
posted @ 2018-03-26 17:16
山里的小勇子
阅读(143)
评论(0)
推荐(0)
摘要:
1、题目描述 Given a string, you need to reverse the order of characters in each word within a sentence while still preserving whitespace and initial word o 阅读全文
posted @ 2018-03-26 16:12
山里的小勇子
阅读(163)
评论(0)
推荐(0)
摘要:
1、题目描述 Initially, there is a Robot at position (0, 0). Given a sequence of its moves, judge if this robot makes a circle, which means it moves back to 阅读全文
posted @ 2018-03-26 15:30
山里的小勇子
阅读(236)
评论(0)
推荐(0)
摘要:
1、题目描述 返回一个 string中最后一个单词的长度。单词定义为没有空格的连续的字符,比如 ‘a’,'akkk'。 2、问题分析 从后向前扫描,如果string是以空格‘ ’结尾的,就不用计数,现将空格最后的空格排除掉,直到找到最后一个出现的字符。从最后一个出现的字符开始计数,一直到下一次出现空 阅读全文
posted @ 2018-03-26 13:44
山里的小勇子
阅读(150)
评论(0)
推荐(0)
摘要:
1、题目描述 反转一个单链表。链表节点结构如下: 2、问题分析 特殊情况是输入的头结点是一个空的,或者只有一个头结点 3、代码实现 阅读全文
posted @ 2018-03-26 10:09
山里的小勇子
阅读(467)
评论(0)
推荐(0)

浙公网安备 33010602011771号