暴力
J1nAB1n9
困困倦倦,浑浑噩噩
展开
-
UVa 725 DIVISION 除法
题目描述: Write a program that finds and displays all pairs of 5-digit numbers that between them use the digits 0through 9 once each, such that the first number divided by the second is equal to an in原创 2017-07-27 18:57:19 · 293 阅读 · 0 评论 -
UVa 140 带宽 Bandwidth
暴力题目注意一下细节应该还是很好ac的;因为题目太多图片和字了,我就决定不排版了。Given a graph (V, E) where V is a set of nodes and E is a set of arcs inV ×V , and an ordering on the elements in V , then the bandwidth of anode v i原创 2017-07-30 15:44:35 · 361 阅读 · 0 评论 -
UVa 208 Firetruck 消防车
The Center City fire department collaborates with the transportation department to maintain mapsof the city which reflects the current status of the city streets. On any given day, several street原创 2017-07-31 15:15:04 · 556 阅读 · 0 评论 -
POJ 3414 Pots 我没有用广搜做
PotsTime Limit : 2000/1000ms (Java/Other) Memory Limit : 131072/65536K (Java/Other)Total Submission(s) : 25 Accepted Submission(s) : 11Special Judge Problem DescriptionYou are given原创 2017-08-06 19:30:21 · 301 阅读 · 0 评论 -
uva 1610 Party Games (贪心+STL字符串)
You’ve been invited to a party. The host wants to divide the guests into 2 teams for party games, withexactly the same number of guests on each team. She wants to be able to tell which guest is on whi原创 2017-08-14 14:02:30 · 350 阅读 · 0 评论 -
UVA - 1395 Slim Span (最小生成树)
点击打开链接原题链接-------------------------------这道题目的要求很有趣, 不是单纯的找最小生成树,而是求最苗条的生成树,即最大边权减去最小边权的值尽量的小。由于题的数据量不大可以直接暴力,即在排序之后枚举每一个边作为最短边,然后枚举剩下的所有的边为最大边。没有连通的节点并入,已经连通的节点跳过。所有也不是特别难AC的题目。#include <iostream&...原创 2018-02-10 03:26:00 · 249 阅读 · 0 评论 -
HDU-6055 Regular polygon (暴力)
HDU-6055 Regular polygon去年多校赛的一道题目,写的时候一直WA,今年回过头来看的时候才发现是自己加了太多没有必要的判断所导致的。。On a two-dimensional plane, give you n integer points. Your task is to figure out how many different regular polygon ...原创 2018-07-16 16:23:36 · 348 阅读 · 0 评论 -
快速输入的模板
暑期集训的时候因为这个快速的输入的模板吃了好大的亏。。所以决定这里留一个。 int read(){ int x=0,f=1; char ch=getchar(); while(ch<'0'||ch>'9'){if(ch=='-')f=-1; ch=getchar();} while(ch>='0'&&ch<='9')...原创 2017-11-10 11:17:52 · 418 阅读 · 0 评论