"Aguin" The third week 5.31-6.6

Source: Internet
Author: User

5.31

2015 Baidu Star Program Design Competition-Preliminary (1) 1001 Super Isaiah Acmer

Actually read the wrong question. To cry.

"If the effectiveness of the hundred-degree is greater than the other side, then the hundred-degree will easily win, not to exercise and proud, his future combat effectiveness will remain in this value, will never change." ”

Greedy. The most powerful person ever to hit a super game. It's good to have one last shot.

Finished reading notes back yards. It seems that reading the wrong question does not affect the process. Because I was the last to play the weaker one.

So I still feel that there is no mistake in the yard. Then it's very confusing why WA.

Finally found that it seems to be no use for LL. I don't believe in love anymore.

(But how to think of their own process than the extension of God Cheng Bully much more annoying)

Aguin

Afternoon again played a Baidu star. However only one was made.

2015 Baidu Star Program Design Competition-Preliminary (2) 1003 board occupy

Each time you put the new black dots in the queue, check that there are no white spots around it that can be blackened.

Aguin

There's something wrong in the back. . I'll see you tomorrow.

6.1

Happy children's Day.

2015 Baidu Star Program Design Competition-Preliminary (2) 1002 Connected pipe

The problem was quite bitter yesterday.

Because at first sight it feels like the smallest spanning tree. So I wrote it first.

Most people were supposed to write DP first. But it doesn't.

I don't know which one is fast. Written by Prim.

After writing the first hair to open the explosion m. The vector that was used to store the image.

Change to the structure of the body map. Continue to explode M.

It was later found that it was superfluous to save the side again. And then he blew up the t again. I'm going to write something else.

But then went to the HDU to fill the question. The code that hasn't changed has gone through.

HDU and BC may not be the same machine, tat.

Ran a few more times. There is a situation where the. 9s+ is present. It's easy to kneel during the game.

Aguin

I wonder if Kruskal will be faster. Then pushed the rewrite.

I had a burst of m when I saved the picture. But see a program of someone else. The array is bigger than me. But there was no M-pop. Very confusing.

The result is to run faster than the prim pull.

The notes were written on the side of the prim. But there is no concept of qaq and less

Aguin

6.2

Want to fill the question. Code for a long time. Eat a T.

This is a busy time. It feels like a waste of time.

Heart tired. It's not a code.

After about one hours, think about wasting so much time anyway. Let's waste some more. It's broken broken falls.

2015 Baidu Star Program Design Competition-Preliminary (1) 1002 Find consecutive numbers

First put a T-drop of the SB line tree.

Aguin

When you see the most value, you want to write the line segment tree. Who knows this is going to happen.

wrote a violent. Handed over more than 10 times. A couple of times. (none of the above)

Copied an optimization. It's over. However. Not happy.

Aguin

6.3

2015 Baidu Star Program Design Competition-Preliminary (1) 10,053 order Rubik's Cube

I didn't find it when I hit the first game. This problem is seldom handed down. But still chose the code this way.

At first the data went wrong. But most people find it troublesome to write.

Remember when I first entered the A association. Siro spoke of displacement. At that time did a very annoying replacement.

Written for several days. It's ugly and long written. And UVA was wrong.

Ask the boss for help. He asked me to re-see if the replacement had been written wrong. And then I left it there without error.

After a few days later handed over again. It's so happy.

When the game was WA. It was later found that only the position of the block was considered. Forget the direction.

(I kinda like the cube.) So ashamed. Entertainment to. Non-racing party. )

See a post in the bar. Ebony teacher told the blind twist in the color direction. However, there is no understanding of color direction and calculation.

link:http://tieba.baidu.com/p/3795808536

So chose the way of stupid. is to label 54 faces ...

After writing the code is ugly. I don't know how to make the label look better.

Aguin

6.4

Fill a question. WA one night. Fight again.

6.5

TAT busy a day no Code program chatter.

6.6

2015 Baidu Star Program Design Competition-Preliminary (1) 1004 KPI

Dragged the subject for two days.

Jia eldest brother once said: Dynamic Maintenance K value This timeless classic problem has always been a lot of solutions: line tree, tree-like array, balance tree, etc...

The two-stack pair that was used to fill black box.

After learning the line tree and tree array, try to pull.

Discretization first. Then the binary method is used to inquire.

At first I thought the two points were wrongly written. Then I found out that discretization was wrong--

Two discretization has been done before. It is the kind that maps the original image to the image and does not need to use the original image again. (I don't know how to say that.)

This needs to be mapped back again. I'm afraid to use the map again. T afraid of.

To copy a discretization. Or two-point search.

Aguin

However, unconsciously learned the magic thing called set Dafa.

The Set collection container implements the data structure of the balanced binary search tree of the red and black tree (red-black trees), and when the element is inserted, it automatically adjusts the arrangement of the binary tree, placing the element in the appropriate position to ensure that the key value of each subtree node is greater than the key value of all nodes of the left subtree. and the key value of all the nodes of the small less right operand subtree; Also, make sure that the height of the left subtree of the root node is equal to the height of the number of words, so that the height of the binary tree is the smallest and thus the fastest retrieval speed. It is important to note that it does not repeatedly insert elements of the same key value and takes ignore processing.

The retrieval of the balanced binary search tree using the sequential traversal algorithm, the retrieval efficiency is higher than that of the vectors, deque, and list containers. In addition, the middle sequence traversal algorithm can be used to traverse the key values from small to large, so it can be understood as the balanced binary search tree when inserting elements, the element key values are automatically ordered from small to large.

The main purpose of constructing a set set is to quickly retrieve, and before using set, you need to include the declaration "#include <set>" in the program header file.

Although I do not know what the red and black trees are. But it looks like a good look. Can't help but copy a set of Dafa.

(Always only know to use set to come and go heavy really hehe iterator what or is the first time use it)

Aguin

2015 Baidu Star Program Design Competition-Preliminary (1) 1003 sequence transformation

Feeling two points has not been written well. In particular, the convergence to the boundary is a mistake.

Then wrote a not troublesome two points + greed.

But I don't know why I can be greedy--b

Aguin

The first two weeks to engage in a moment Baidu star. Although not a few questions and early was eliminated.

But I feel like playing this occasionally. See the world. It's kind of helpful, too.

Can make up a little to fill the next. The rest is out of the way.

The integral system canceled hahaha haha.

We're going to test level four next week. To test the recent history.

Good! Afraid! Afraid!

"Aguin" The third week 5.31-6.6

Related Article

Contact Us

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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.