Escape Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 16    Accepted Submission(s): 12 Problem Description Given a maze of size n×m. The rows are numbered 1, 2, · · · , n from top to bottom w…
Decimal Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 103    Accepted Submission(s): 49 Problem Description Given a positive integer n, determine if 1n is an infinite decimal in decimal base…
Invoker Time Limit: 15000/12000 MS (Java/Others)    Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 117    Accepted Submission(s): 35 Problem Description In dota2, there is a hero named Invoker. He has 3 basic skills in the game, whic…
传送门 题意: 给出一个\(n*m\)的迷宫,有\(a\)个入口,\(b\)个出口. 现在有\(a\)个机器人都从入口出发,一开始方向默认为下,你可以选在在一些格子上面放置一个转向器,转向器有四种: 向下走变为向右走: 向下走变为向左走: 向上走变为向右走: 向上走变为向左走. 每个格子最多放一个转向器. 问最后是否存在一种方案,使得每个机器人都能到达从其中一个出口. 思路: 因为题目要求转向器只能接受固定方向,并且变为固定方向,所以有几个比较重要的观察: 不存在两个机器人的路线共线: 若一个格…
https://www.cnblogs.com/31415926535x/p/11625462.html 昨天和队友模拟了下今年秦皇岛的区域赛,,,(我全程在演 题目链接 D - Decimal 签到题,,,(感觉在cf上做过,, (然后写反输出白白wa一发,,,,,emmmmmmmm F - Forest Program 这题我感觉是第二道签到题,,,很简单,,但是我一个人读完题后就想着怎么写代码,,,然后wa了无数发才反应过来还要考虑树边的情况,,,丧失理智 ,,,, 题意就是给一个 仙人掌…
BaoBao is trapped in a one-dimensional maze consisting of  grids arranged in a row! The grids are numbered from 1 to  from left to right, and the -th grid is marked with a character , where  is either 'L' or 'R'. Starting from the -th grid, BaoBao wi…
练了一年半了,第一次打CCPC,险些把队友坑了打铁,最后也是3题危险捡了块铜. 非常水的点双连通,我居然不相信自己去相信板子,唉,结果整来整去,本来半个小时能出的题,整到了3个小时,大失误呀,不然就可以去弄其他题了,对自己的表现太失望了,给自己记一大过.然后导致了策略失误,稀里糊涂的时间久过去了,不然感觉我们队还是能再出3题的. 可惜可惜,自己的这些大赛的经验还是不足,但相信这不会成为拖累自己队伍的后腿,发现问题就要及时调整,在赛场上还是要坚信自己所想到的,不用太苛求于模板形式. 有些急躁,但心…
Drainage Ditches 题目抽象:给你m条边u,v,c.   n个定点,源点1,汇点n.求最大流.  最好的入门题,各种算法都可以拿来练习 (1):  一般增广路算法  ford() #include <iostream> #include <cstdio> #include <cstring> #include <cmath> #include <algorithm> #include <string> #include…
题目链接 给一个n*m的图, 里面有一些点, '.'代表空地, '#'代表墙, 不可以走, '@'代表大门, 可以有多个, 'X'代表人, 问所有人都走出大门需要的最短时间, 每一时刻一个格子只能有一个人, 每个时刻只能有一个人从大门走出, 如果不能走出, 输出-1. 先dfs判断是否每个人都能走出, 如果有人不能, 直接输出-1. 从小到大枚举时间, 对于枚举的时间t, 每个格子i, j向它四周以及他本身建边, ( i*m+j+(t-1)*nm, x*m+y+t*nm, 1), 这样就相当于t…
Secret Milking Machine Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 8189   Accepted: 2485 Description Farmer John is constructing a new milking machine and wishes to keep it secret as long as possible. He has hidden in it deep within…