hdu4772 水模拟】的更多相关文章

题意:       给你两个矩阵,问你两个矩阵的最大相同元素个数(位置也要求相同),矩阵可以90旋转多次. 思路:       水题,直接模拟就行了,方法很多,可以直接写坐标关系,或者一层一层处理,就是一层一层往里拿出来,比较就行了,两个都写了. 直接交换 #include<stdio.h> int A[32][32] ,B[32][32] ,C[32][32]; void swap(int n) {    for(int i = 1 ;i <= n ;i ++)    for(int…
CodeForces.158A Next Round (水模拟) 题意分析 校赛水题的英文版,坑点就是要求为正数. 代码总览 #include <iostream> #include <cstdio> #include <algorithm> #include <cstring> #include <sstream> #include <set> #include <map> #include <queue>…
CodeForces71A. Way Too Long Words (水模拟) 题意分析 题怎么说你怎么做 没有坑点 代码总览 #include <iostream> #include <cstdio> #include <algorithm> #include <cstring> #include <sstream> #include <set> #include <map> #include <queue>…
A. Broken Clock time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output You are given a broken clock. You know, that it is supposed to show time in 12- or 24-hours HH:MM format. In 12-hours format…
A. Combination Lock time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output Scrooge McDuck keeps his most treasured savings in a home safe with a combination lock. Each time he wants to put there…
A. Neverending competitions time limit per test 2 seconds memory limit per test 512 megabytes input standard input output standard output There are literally dozens of snooker competitions held each year, and team Jinotega tries to attend them all (f…
BZOJ水一道~ 枚举前两个位置是否放雷,模拟向下推.能够则ans++ #include "stdio.h" #include "string.h" int a[10010],b[10010],n; int judge() { int i; for (i=3;i<=n;i++) { b[i]=a[i-1]-b[i-1]-b[i-2]; if (b[i]<0) return 0; if (b[i]>1) return 0; } if (b[n-1]+…
A. The New Year: Meeting Friends time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output There are three friend living on the straight line Ox in Lineland. The first friend lives at the point x1, t…
A. One-dimensional Japanese Crossword time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Recently Adaltik discovered japanese crosswords. Japanese crossword is a picture, represented as a tabl…
A. Calculating Function time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output For a positive integer n let's define a function f: f(n) =  - 1 + 2 - 3 + .. + ( - 1)nn Your task is to calculate f(n…