码迷,mamicode.com
首页 >  
搜索关键字:lower    ( 3122个结果
UVa 156 map的使用
背景:主要是学习map相关知识,详见代码 我的代码:#include #include #include #include #include using namespace std; map map1; mapmap2; vector vector1,ans; string string1_lower(string string1){ for(int i=0;i < stri...
分类:其他好文   时间:2015-02-06 09:38:26    阅读次数:106
uva10474大理石在哪儿where is the marble?
背景:做了这么久的题,唯一一道一次ac的,可见这道题是如何的简单。 思路:思路很清楚的模拟题,先排序再查找。 学习:sort函数和lower_bound函数,sort函数排序就不多说了,lower_bound函数作用是查找一个数组中大于等于x的第一个位置。#include #include #include using namespace std; int figue[10000]; v...
分类:其他好文   时间:2015-02-05 23:25:29    阅读次数:176
[leetcode] Anagrams
AnagramsGiven an array of strings, return all groups of strings that are anagrams.Note: All inputs will be in lower-case.思路:什么是anagrams?傻逼了,百度吧。一百度全是别...
分类:其他好文   时间:2015-02-04 23:02:59    阅读次数:137
Length of Last Word
Given a stringsconsists of upper/lower-case alphabets and empty space characters' ', return the length of last word in the string.If the last word doe...
分类:其他好文   时间:2015-02-03 14:37:44    阅读次数:128
[leetcode] Length of Last Word
Length of Last Word  Total Accepted: 32811 Total Submissions: 113876My Submissions Question  Solution  Given a string s consists of upper/lower-case alphabets and empty space charact...
分类:其他好文   时间:2015-02-01 16:12:14    阅读次数:148
1062 Talent and Virtue (25)
1 /* 2 3 4 L (>=60), the lower bound of the qualified grades -- 5 that is, only the ones whose grades of talent and virtue are both not below...
分类:其他好文   时间:2015-02-01 08:28:31    阅读次数:171
【leetcode】Length of Last Word
前段时间忙数据交换,有一个多月没写java了。。找找手感,刷刷题吧。。 去leetcode上挑了个简单的,题目是这样的。 Given a string s consists of upper/lower-case alphabets and empty space characters ' ', return the length of last word in the strin...
分类:其他好文   时间:2015-01-31 19:28:22    阅读次数:168
Anagrams -- leetcode
Given an array of strings, return all groups of strings that are anagrams. Note: All inputs will be in lower-case. 算法思路: 将单词进行排序。 用map统计排序后相等的出现次数。 将次数大于1的单词放入结果集。 第1次出现时,因次数最终是否大于1不明郎,将其暂存入...
分类:其他好文   时间:2015-01-31 16:29:04    阅读次数:153
UVa 1152 4Values whose Sum is 0
题意  从4个n元集中各挑出一个数  使它们的和为零有多少种方法 直接n^4枚举肯定会超时的  可以把两个集合的元素和放在数组里  然后排序 枚举另外两个集合中两元素和  看数组中是否有其相反数就行了  复杂度为n^2*logn #include #define l(i) lower_bound(s,s+m,i) #define u(i) upper_bound(s,s+m,i) using...
分类:其他好文   时间:2015-01-29 12:47:43    阅读次数:196
【HighCharts系列教程】五、版权属性——Credits
一、Credits属性说明严格来讲,Credits并不算版权信息,官方的说法是:Highchart by default putsa credits label in the lower right corner of the chart。不管怎样的说法,在自己的图表加上HighCharts字样并有...
分类:其他好文   时间:2015-01-27 17:50:00    阅读次数:167
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!