- 博客(11)
- 资源 (2)
- 收藏
- 关注
原创 9、strchr函数&strtok函数&strdup使用
题意: 将字符串abcddd#123#gaghah#345#fdsafa#345#中把#之间的数字串替换成对应的字母串123===》defd345===》fdse#include<iostream>#include<stdio.h>#include<stdlib.h>#include<cstring>#include<st...
2018-12-26 00:01:44 403
原创 42. Trapping Rain Water
Given n non-negative integers representing an elevation map where the width of each bar is 1, compute how much water it is able to trap after raining.The above elevation map is represented by array...
2018-12-23 01:04:57 152
原创 41. First Missing Positive
Given an unsorted integer array, find the smallest missing positive integer.Example 1:Input: [1,2,0]Output: 3Example 2:Input: [3,4,-1,1]Output: 2Example 3:Input: [7,8,9,11,12]Outpu...
2018-12-22 15:49:29 309
原创 40. Combination Sum II
Given a collection of candidate numbers (candidates) and a target number (target), find all unique combinations in candidates where the candidate numbers sums to target.Each number in candidates may...
2018-12-22 11:53:24 271
原创 39. Combination Sum
Given a set of candidate numbers (candidates) (without duplicates) and a target number (target), find all unique combinations in candidates where the candidate numbers sums to target.The same repeat...
2018-12-21 17:18:36 164
原创 8、读取文件夹下的文件名
题意:处理指定路径下,文件夹的文件;#include <stdio.h>#include <string.h>#include <sys/types.h>#include <dirent.h>#include <sys/stat.h>char filename[256][256];int len = 0;int tra...
2018-12-12 22:55:11 523
原创 22、CCF-201809-2-买菜
试题编号: 201809-2 试题名称: 买菜 时间限制: 1.0s 内存限制: 256.0MB 问题描述: 问题描述 小H和小W来到了一条街上,两人分开买菜,他们买菜的过程可以描述为,去店里买一些菜然后去旁边的一个广场把菜装上车,两人都要买n种菜,所以也都要装n次车。具体的,对于小H来说有n个不相交的时间段[a1,b1],[a2,...
2018-12-09 20:43:33 237
原创 21、CCF-201809-1-卖菜
试题编号: 201809-1 试题名称: 卖菜 时间限制: 1.0s 内存限制: 256.0MB 问题描述: 问题描述 在一条街上有n个卖菜的商店,按1至n的顺序排成一排,这些商店都卖一种蔬菜。 第一天,每个商店都自己定了一个价格。店主们希望自己的菜价和其他商店的一致,第二天,每一家商店都会根据他自己和相邻商店的价格调整自...
2018-12-09 14:18:25 290
原创 38. Count and Say
The count-and-say sequence is the sequence of integers with the first five terms as following:1. 12. 113. 214. 12115. 1112211 is read off as "one 1" or 11.11 is read off ...
2018-12-08 16:37:52 140
原创 36. Valid Sudoku
Determine if a 9x9 Sudoku board is valid. Only the filled cells need to be validated according to the following rules:Each row must contain the digits 1-9 without repetition. Each column must co...
2018-12-06 13:41:44 163
原创 7、C语言比比两个文本文件的内容差异以及中英文字符匹配
#include <stdio.h>#include <string.h>#define MAXLEN 257#define MAXLEN 257void CompareFile(FILE *fa,FILE *fb,FILE *flog) {char sa[MAXLEN],sb[MAXLEN],temp[MAXLEN],flag;fgets(sa,MAXLEN...
2018-12-05 14:57:19 7918 1
2017最全的vivado license
2017-03-19
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人