This is really an interesting question. I don't know what others think. In short, I think this question is really interesting and worth doing. Attach a question first:
There are lots of number games for children. these games are pretty easy to play
Question: intersection, merger, subtraction, and population
Idea: Use the leaf node of the Line Segment tree to record whether the point is covered by the interval. Because of the open interval, consider discretization and multiply the value by 2.
U:
Question:The start position is 0. Each step can be left or not moved to the right. After n steps are taken, the path can reach the rightmost expectation.
Solution:
During the competition, the question was wrong and thought it was necessary to return
# Include # include # include # include # include # include # include using namespace std; int main () {int n; int id, g; while (scanf ("% d", & n) {map m; m [1000000000] = 1; for (int I = 1; I : iterator it; it = m. lower_bound (g); //
Original question: HDU 4528 James series story-hide-and-seek
Analysis: Add two statuses when marking.
Code:
#include #include #include #include using namespace std; const int maxn=101; char f[maxn][maxn]; int dx[]={0,0,-1,1}; int dy[]=
Problem EForeign ExchangeInput: standard inputOutput: standard outputTime Limit: 1 second
Your non-profit organization (iCORE-international Confederation of Revolver Enthusiasts) coordinates a very successful foreign student exchange program. over
Problem DescriptionAkemi Homura is a Mahou Shoujo (Puella Magi/Magical Girl ).
Homura wants to help her friend Madoka save the world. But because of the plot of the Boss Incubator, she is trapped in a labyrinth called LOOPS.
The planform of the
High-Precision arbitrary Conversion
The code is found in discuss and is said to have been written by maigo.
Ultra-Simplified !!
In my first writing, I first converted the n-base to the 10-base, and then converted the n-base to the m-base...
Sadly,
You 've been invited to a party. the host wants to divide the guests into 2 teams for party games, with exactly the same number of guests on each team. she wants to be able to tell which guest is on which team as she greets them when they arrive.
I should use hash for the question of the 11386 Triples of the uva, and use STL map to time out. But I wrote two parts by hand and added some optimization. The time limit is 8 seconds. I got stuck in 7.8 seconds. It's great!
This question has been
# Include # include # include # include # include # include # include # include # include # include # include # include # include # include # include # define FF (I, a, B) for (int I = a; I = B; I --) # define REP (I, n) for (int I =
232/UK44i/334sda # nh $ X3y/Appx-301a At this moment, through out Europe, our base station numbers 1 to N are actively operational through wireless channels. immediately we require sendingC secret message fragments from our head quarters (base
Uva-11456, hdu-3165 Irene is a train mechanic, she is also responsible for car scheduling. She liked to sort the carriage by weight from large to small, and put the heaviest carriage in front of the train. Unfortunately, it is not easy to arrange
Divide and conquer as the final example (You must be bored with the vivid code and want to go back to the linguistic discussion about the comparison and abstraction criteria). Let's make a small super computing. Then have a cup of coffee. Our super
Well, how do you feel about mobile phone? Your answer wowould probably be something like that "It's so convenient and benefits people a lot ". however, If you ask Merlin this question on the New Year's Eve, he will definitely answer "What a trouble!
Although this concept has been widely used, I still want to record it for future queries. # Ifdef _ DEBUG # define DEBUG_CLIENTBLOCK new (_ CLIENT_BLOCK, _ FILE __, _ LINE _) # else # define DEBUG_CLIENTBLOCK # endif # define _ CRTDBG_MAP_ALLOC #
There are three cases of normal cell classification. 1. simple stage OA // O represents the healthy cell classification form, which indicates that the simple stage is in progress. 2. fully-grown stage OAB // O represents the healthy cellular
Zjnu StadiumTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission (s): 729 Accepted Submission (s ): 297 Problem DescriptionIn 12th Zhejiang College Students Games 2007, there was a new stadium built in
Solve the cycle problem, simple KMP --
AC code:
# Include # Include # Include # Include # Include # Include # Include # Include # Include # Include # Include # Include # Include # Include # Include # Include Using namespace std; Typedef long
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service