
bfs
biu________
这个作者很懒,什么都没留下…
展开
-
抓牛
https://vjudge.net/contest/65959#problem/CFarmer John has been informed of the location of a fugitive cow and wants to catch her immediately. He starts at a point N (0 ≤ N ≤ 100,000) on a number line ...转载 2018-04-20 20:35:21 · 263 阅读 · 0 评论 -
棋盘问题
在一个给定形状的棋盘(形状可能是不规则的)上面摆放棋子,棋子没有区别。要求摆放时任意的两个棋子不能放在棋盘中的同一行或者同一列,请编程求解对于给定形状和大小的棋盘,摆放k个棋子的所有可行的摆放方案C。2 1 #. .# 4 4 ...# ..#. .#.. #... -1 -1 #include<iostream> #include<cstdio> #include<...转载 2018-04-20 20:42:01 · 155 阅读 · 0 评论 -
0、1整除
题意:找出任意一个由0和1组成的数,而且是n的倍数。unsigned __int64可以存下结果,循环深度<20;两条搜索路径---t*10;t*10+1;#include<iostream> #include<cstdio> #include<cstring> #include<algorithm> using namespace s...转载 2018-04-21 00:06:02 · 303 阅读 · 0 评论 -
总统素数
将一个素数变成另一个素数,且过程均为素数 #include <iostream> #include <algorithm> #include <cstring> #include <cstdio> #include <math.h> #include <cstdlib> #include <queue>转载 2018-04-21 15:38:30 · 118 阅读 · 0 评论 -
素数环
A ring is composed of n (even number) circles as shown in diagram.Put natural numbers 1, 2, . . . , n into each circle separately, and the sum of numbers in two adjacent circles should be a prime.Note...原创 2018-05-11 17:50:30 · 352 阅读 · 0 评论 -
无相邻重复字符串(广搜)
Krypton Factor You have been employed by the organisers of a Super Krypton Factor Contest in which contestants have very high mental and physical abilities. In one section of the contest the contesta...原创 2018-05-11 20:12:08 · 1252 阅读 · 0 评论