摘要: 题目 DZY loves chemistry, and he enjoys mixing chemicals. DZY has n chemicals, and m pairs of them will react. He wants to pour these chemicals into a t 阅读全文
posted @ 2022-01-23 23:31 Benincasa 阅读(22) 评论(0) 推荐(0) 编辑
摘要: 题目 A frog lives on the axis Ox and needs to reach home which is in the point n. She starts from the point 1. The frog can jump to the right at a dista 阅读全文
posted @ 2022-01-23 23:19 Benincasa 阅读(83) 评论(0) 推荐(0) 编辑
摘要: 题目Given a sequence of integers S = {S1, S2, . . . , Sn}, you should determine what is the value of themaximum positive product involving consecutive t 阅读全文
posted @ 2022-01-23 23:06 Benincasa 阅读(23) 评论(0) 推荐(0) 编辑
摘要: 题目 Bob is a farmer. He has a large pasture with many sheep. Recently, he has lost some of them due to wolf attacks. He thus decided to place some shep 阅读全文
posted @ 2022-01-23 23:02 Benincasa 阅读(37) 评论(0) 推荐(0) 编辑
摘要: 题目 译自 POI 2007 Stage 2. Day 0「Ridges and Valleys」 给定一个 n \times nn×n 的网格状地图,每个方格 (i,j)(i,j) 有一个高度 w_{ij}wij​。如果两个方格有公共顶点,则它们是相邻的。 定义山峰和山谷如下: 均由地图上的一个连 阅读全文
posted @ 2022-01-23 22:52 Benincasa 阅读(156) 评论(0) 推荐(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 thesum of num 阅读全文
posted @ 2022-01-23 22:30 Benincasa 阅读(20) 评论(0) 推荐(0) 编辑
摘要: 题目Given an n ∗ m chessboard with some marked squares, your task isto place as few queens as possible to guard (attack or occupy) allmarked squares. Be 阅读全文
posted @ 2022-01-23 22:14 Benincasa 阅读(24) 评论(0) 推荐(0) 编辑
摘要: 题目 There is a grid, consisting of nn rows and mm columns. Each cell of the grid is either free or blocked. One of the free cells contains a lab. All t 阅读全文
posted @ 2022-01-23 21:58 Benincasa 阅读(32) 评论(0) 推荐(0) 编辑
摘要: 题目 小Q正在设计一款2D卡丁车游戏,你的任务是帮助小Q实现其中的一部分功能。 在这款游戏中,游戏地图是一张 nn 行 mm 列的网格,从上到下依次编号为第 11 行到第 nn 行,从左往右依次编号为第 11 列到第 mm 列,其中第 ii 行第 jj 列的格子的坐标为 (i,j)(i,j),每个格 阅读全文
posted @ 2022-01-23 21:34 Benincasa 阅读(64) 评论(0) 推荐(0) 编辑
摘要: 题目 Monocarp is playing a computer game. Now he wants to complete the first level of this game. A level is a rectangular grid of 22 rows and nn columns 阅读全文
posted @ 2022-01-23 21:30 Benincasa 阅读(103) 评论(0) 推荐(0) 编辑
摘要: 题目描述 原题来自:POJ 1915 编写一个程序,计算一个骑士从棋盘上的一个格子到另一个格子所需的最小步数。骑士一步可以移动到的位置由下图给出。 输入格式 第一行给出骑士的数量 nn。在接下来的 3n3n 行中,每 33 行描述了一个骑士。其中, 第一行一个整数 LL 表示棋盘的大小,整个棋盘大小 阅读全文
posted @ 2022-01-23 21:25 Benincasa 阅读(63) 评论(0) 推荐(0) 编辑