原题:https://pintia.cn/problem-sets/15/problems/890
0 | sample 1 无冲突 | 答案正确 |
6 | 4 ms | 452 KB |
1 | sample 2 有冲突 | 答案正确 |
8 | 5 ms | 320 KB |
2 | 有重复关键字 | 答案正确 |
3 | 5 ms | 448 KB |
3 | 最大和最小字符串,以及不足3位的字符串 | 答案错误 |
0 | 5 ms | 324 KB |
4 | 最大N,随机 | 答案正确 |
5 | 6 ms | 324 KB |
整了半天,也调试了许多例子,愣是没发现哪里错了。。
暂且搁着,等有缘人相助。。
#include<iostream>
#include<string>
#include<math.h>
#include<map>
using namespace std;
map <string, int> mp;
int vis[1010];
int ch(char op) { return op - 'A'; }
int main()
{
int n, p