原创 LA 2995 & ZOJ2714 Image is Everything

Image is Everything Time Limit: 2 Seconds Memory Limit: 65536 KB Your new company is building a robot that can hold s

原创 2678 - Subsequence

A sequence of N positive integers (10 < N < 100 000), each of them less than or equal 10000, and a positive integer S (

原创 POJ3126Prime_Path

Prime Path Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 13020   Accepted: 7364 Description The mi

原创 LA3695 - Distant Galaxy

Input  There are multiple test cases in the input file. Each test case starts with one integer N , (1N100) , the num

原创 AOJ0009Prime Number

Prime Number Write a program which reads an integer n and prints the number of prime numbers which are less than or

原创 Uva10795 - A Different Task

The (Three peg) Tower of Hanoi problem is a popular one in computer science. Brie y the problem is to transfer all the

原创 Uva 11210 - Chinese Mahjong

Input The input consists of at most 50 test cases. Each case consists of 13 tiles in a single line. The hand is legal (

原创 LA 3708 - Graveyard

Programming contests became so popular in the year 2397 that the governor of New Earck -- the largest human-inhabited p

原创 Uva 10881 - Piotr's Ants

"One thing is for certain: there is no stopping them; the ants will soon be here. And I, for one, welcome our new inse

原创 Uva11520 - Fill the Square

In this problem, you have to draw a square using uppercase English Alphabets. To be more precise, you will be given a s

原创 第六屆藍橋杯2015-省賽-C語言大學B組 個人題解

題目連接:http://course.baidu.com/view/2d86a6c1960590c69fc37622.html 1,獎券數目52488 #include <iostream> using namespace std; b

原创 Uva11464 - Even Parity

We have a grid of size N  N. Each cell of the grid initially contains a zero(0) or a one(1). The parity of a cell is th

原创 LA3902 - Network

Consider a tree network with n nodes where the internal nodes correspond to servers and the terminal nodes correspond t

原创 POJ1930Dead Fraction

Dead Fraction Time Limit: 1000MS   Memory Limit: 30000K Total Submissions: 2097   Accepted: 669 Description Mike

原创 LA3635 - Pie

My birthday is coming up and traditionally I'm serving pie. Not just one pie, no, I have a number N of them, of various