1078 字符串压缩与解压 (20分) https://pintia.cn/problem-sets/994805260223102976/problems/994805262018265088 1 #include <cstdio> 2 #include <cstring> 3 #include ...
分类:
其他好文 时间:
2020-01-16 23:44:37
阅读次数:
83
https://pintia.cn/problem-sets/12/problems/346 这个程序的算法不难,因为没有学透标准输入和输出,特别是gets()函数。如果不用getchar()读取多余的'\n',程序就会运行错误。 1 #include <stdio.h> 2 #include <s ...
分类:
其他好文 时间:
2020-01-16 21:48:57
阅读次数:
97
1079 延迟的回文数 (20分) https://pintia.cn/problem-sets/994805260223102976/problems/994805261754023936 1 #include <cstdio> 2 #include <cstring> 3 #include <s ...
分类:
其他好文 时间:
2020-01-16 21:42:51
阅读次数:
70
https://pintia.cn/problem-sets/12/problems/342 1 bool palindrome(char *s) 2 { 3 int n, i, k; 4 bool ret; 5 6 n = strlen(s); 7 i = 0; 8 k = n - 1; 9 wh ...
分类:
其他好文 时间:
2020-01-14 20:59:58
阅读次数:
89
1009 说反话 (20分) 题目地址:https://pintia.cn/problem sets/994805260223102976/problems/994805314941992960 给定一句英语,要求你编写程序,将句中所有单词的顺序颠倒输出。 输入格式: 测试输入包含一个测试用例,在一 ...
分类:
其他好文 时间:
2020-01-13 22:04:56
阅读次数:
62
本文详细介绍和说明了mongodb复制集(Replica sets)+分片(Sharding)环境的搭建步骤和具体方法,记录于此,供各位同学及自己参考研究。 ...
分类:
数据库 时间:
2020-01-12 11:32:56
阅读次数:
118
1. Handling missing keys with setdefault import sys import re WORD_RE = re.compile('\w+') index = {} print(sys.argv) # Example 3-2 with open(sys.argv[ ...
分类:
其他好文 时间:
2020-01-12 09:40:44
阅读次数:
86
原题链接 https://pintia.cn/problem sets/994805342720868352/problems/994805521431773184 思路 很明显这题需要用到树这个数据结构,问题是怎么来存。一开始我是这样想的:因为它只问了每一层叶子结点数,所以最简单的情况下我只需要两 ...
分类:
其他好文 时间:
2020-01-11 20:20:35
阅读次数:
67
1007 素数对猜想 (20分) 题目地址:https://pintia.cn/problem sets/994805260223102976/problems/994805317546655744 输入格式: 输入在一行给出正整数 。 输出格式: 在一行中输出不超过 的满足猜想的素数对的个数。 输 ...
分类:
其他好文 时间:
2020-01-11 18:27:27
阅读次数:
68
导读: 第一节:基础架构 1:编程模型 2:架构 3:数据传输 4:高可靠性 5:高维护性 6:数据处理方式 7:对比MR,SPARK 第二节:计算模型 1:spout 2:bolt 3:stream grouping 4:构建拓扑与提交 第三节:架构 第四节:部署 第五节:数据处理 1:同步计算 ...
分类:
其他好文 时间:
2020-01-09 20:56:24
阅读次数:
117