
STL
西瓜君wtml
这个作者很懒,什么都没留下…
展开
-
hdu 1671 STL
Problem Description Given a list of phone numbers, determine if it is consistent in the sense that no number is the prefix of another. Let’s say the phone catalogue listed these numbers: 1. Emergency原创 2017-08-31 08:22:45 · 226 阅读 · 0 评论 -
hdu 1425 快排
Problem Description 给你n个整数,请按从大到小的顺序输出其中前m大的数。Input 每组测试数据有两行,第一行有两个数n,m(0题解:此题可以用qsort,sort,堆排序 qsort,sortC++会超时,G++可以ACqsort代码:#include <iostream> #include <cstdio> #include <algorithm> using name原创 2017-09-16 09:09:01 · 562 阅读 · 0 评论 -
51nod 1095 Anigram单词
1095 Anigram单词一个单词a如果通过交换单词中字母的顺序可以得到另外的单词b,那么定义b是a的Anigram,例如单词army和mary互为Anigram。现在给定一个字典,输入Q个单词,从给出的字典中找出这些单词的Anigram。 Input 第1行:1个数N,表示字典中单词的数量。(1 <= N <= 10000) 第2 - N + 1行,字典中的单词,单词长度 <= 10。原创 2017-08-16 21:57:54 · 237 阅读 · 0 评论 -
hdu 1062 Text Reverse
Input The input contains several test cases. The first line of the input is a single integer T which is the number of test cases. T test cases follow. Each test case contains a single line with sever原创 2017-08-02 16:11:53 · 298 阅读 · 0 评论 -
hdu 2095 map水
Problem Description In the new year party, everybody will get a “special present”.Now it’s your turn to get your special present, a lot of presents now putting on the desk, and only one of them will b原创 2017-08-03 21:51:29 · 275 阅读 · 0 评论 -
51nod 拼成最小的数 STL技巧
1097 拼成最小的数 基准时间限制:1 秒 空间限制:131072 KB 分值: 20 难度:3级算法题 收藏 关注 设有n个正整数,将它们联接成一排,组成一个最小的多位整数。例如: n=2时,2个整数32,321连接成的最小整数为:32132, n=4时,4个整数55,31,312, 33 联接成的最小整数为:312313355 Input 第1行:1个数N。(2 <= N <=原创 2018-04-08 10:06:35 · 181 阅读 · 0 评论 -
B. Substrings Sort STL
B. Substrings Sort time limit per test1 second memory limit per test256 megabytes inputstandard input outputstandard output You are given n n strings. Each string consists of lowercase English...原创 2018-06-09 19:35:18 · 228 阅读 · 0 评论