Chapter 34: Big Brush
Ye Ming had a look on his face.
He thought that Shen Ruhai was just asking casually, but he didn't expect that this guy was more serious......
Looking at the phone, he suddenly felt that the phone was a little hot.
What to do? Brush now? But it's too late to brush now......
After thinking about it, Ye Ming gritted his teeth and simply pretended to be dead.
Anyway, as long as anyone who has contacted him knows, his WeChat messages often lag behind for half a day.
At the moment when the screen of the mobile phone turned off, the private chat message of Paint and Mo jumped out.
"You must not have brushed, did you?" A Sherlock Holmes expression followed.
Ye Ming panicked in his heart, and immediately replied: "Shhh, don't tell the captain, I'm really not free lately." β
Lacquer & Ink: "Hehe, I know." β
Ye Ming: "Did you brush it?" β
Paint and ink: "I registered an account during the Spring Festival, and I'm doing it intermittently. The questions of the force buckle are not very difficult, and they tend to be on the market, but they are good at a wide range and can train competition habits. So I've brushed more than 100 in the past half a month. β
Hearing Qi and Mo say this, Ye Ming understood why Shen Ruhai wanted to let him post an account.
Feelings are because they open their mouths to be hundreds......
"It's a little irritable, then I'll pick a simple brush, and you can help me round it out in the group."
Lacquer and ink made a "easy to say" expression: "Treat? β
"No problem, I will definitely wait for the game to come back!"
"Oh, by the way, when does your game start? When to go? β
"On the 28th, this afternoon's bullet train, tomorrow morning."
"Then I wish you all the best and return home with a victory! Have a nice trip! β
"Lend you good words."
Ye Ming turned off his phone with a smile.
Qi and Mo agreed to join the team in the science and technology museum that day, but in the end they only stayed on their lips and did not really join - the mid-term review has already passed, and even if she really joins, she cannot be regarded as a member of the competition, and she will not be able to win the award.
After thinking about it, he sighed and sat down in front of the computer.
He also said that he would start teaching Ita physics class today.
Landing the force buckle, Ye Ming glanced at it a few times, and he didn't know where he should start, so he simply clicked "random question".
LCP 21. Chase Game
Xiao Li and Xiao Buckle in the autumn tour designed a chase game. They selected N scenic spots in the autumn market scenic area, and the attractions are numbered 1~N. In addition, they also chose N trails so that any two attractions can be reached by each other, and there are no two trails that connect the same attractions. The entire game scene can be viewed as an undirected connectivity graph, which is denoted as a two-dimensional array of edges, in which [a,b] indicates that there is a path between attraction A and attraction B.
β¦β¦
Note: Small force and small buckle will always adopt the optimal movement strategy.
Ye Ming took a look at the example and found that this is an algorithm problem of DFS (Depth First Search) and BFS (Width First Search).
Then it is nothing more than finding the ring according to the example questions, then discussing the situation, and finally enumerating.
After a little thought, Ye Ming began to write down the code.
#define INF 0x3f3f3f3f
class Solution {
vector> adj;
vector depthοΌ parent;
vector in_loop;
int nοΌ loop = 0;
β¦β¦
Ye Ming crackled and wrote nearly 70 lines of code, and after clicking on the execution, he directly chose to submit.
Three seconds later.
The system returns the submission result.
Execution time: 268 ms, beating 87.69% of users across all C++ commits.
Memory consumption: 80.8 MB, beating 88.61% of users across all C++ commits
Pass test cases: 55/55
Looking at the results, Ye Ming was a little stunned.
This execution time and memory consumption are only in the top 20 percent?
"it!"
Ye Ming sat up straight for a moment.
With the blessing of the system, learning may be a little too easy for him to say that it is as easy as eating.
But it's hard to ...... That's certainly not hard.
Let's put it this way, he only needs to read a book with his own knowledge base with his brain, as long as it is not rare to go against the sky, then after reading it, he can understand.
This is the "sequelae" that came to him after he understood the buff.
It's in quotation marks because it's a good thing.
The three major buffs of the system, in layman's terms, are the short-term "development" and "overclocking" of his brain - such as the pseudoscientific claims that Einstein's brain has reached a few percent of the development.
As we all know, concentration, insight, and understanding are all abilities, and even if they are only improved in a short period of time, they will have a subtle long-term impact.
So now Ye Ming, even if he doesn't use BUFF, he also has the ability to learn and solve problems beyond ordinary people.
"You really can't underestimate the heroes of the world."
Ye Ming took a few breaths in succession, looking at the result of this submission with great emotion.
He then started checking the code.
Time passed minute by minute.
When Ye Ming continued to modify the code, after the fourth submission, the website finally returned a satisfactory result.
Execution time: 201ms, beating 99.99% of users across all C++ commits
Memory consumption: 60.8 MB, beating 99.99% of users out of all C++ commits
Ye Ming exhaled a long breath, and a smile rose.
Comfortable!
One more question!
Oh, binary, simple.
Then come again......
β¦β¦
With one more question again and again, Ye Ming brushed directly from nine o'clock in the morning to half past four in the afternoon.
Except for the first few courses, Ye Ming wants to pursue and surpass everyone. He kept a calm mind on the following topics, and didn't care about the execution efficiency or anything, and then talked about the code first.
Because of this thing ...... efficiency It's really not something that can be done in a competitive environment.
It was a cup of tea, a pack of cigarettes, and a day of squatting in front of a monitor.
There was no need for him to fight on this.
"Let's go, let's gather."
Just as Ye Ming clicked the submit button for question 130, Peng Xiaofei opened the bedroom on his shoulder.
In the next second, his eyes widened: ", did you brush up on the questions for a day today?" β
"Well, I swiped it."
Ye Ming closed his somewhat dry eyes hard, moved his neck again, and directly buckled the monitor.
Peng Xiaofei is good anywhere, but it's a little fussed.
If you let this product know that you have swiped 130 in one day, you may not know what this product will shout about.
"Let's go, do you want to eat and go to the station or what?"
"Let's have a departure ceremony first."
ββ¦β¦ Formalism. β
"I think too, but this time we have great hopes, so we can do it."
"Alas......" Ye Ming stood up.
β¦β¦
At 7 o'clock in the evening, a group of ten people got on the bus on time.
With a silent acceleration, the high-speed train slowly drove out of the East Station.
Ye Ming, who was tired for a day, fell asleep on the chair not long after he got in the car.
Then when he opened his eyes, it was already early in the morning.
It had become quiet, and even outside the window it was pitch black.
He glanced around, and saw that his teammates had fallen asleep, and only the captain Li Dongsheng who was sitting opposite was still playing with his mobile phone, and he looked up from time to time.
Seeing Ye Ming wake up, Li Dongsheng raised his chin at him, lowered his voice and said, "If you wake up, then I will sleep for a while, and when you want to sleep again, call Lao Jiang Ha." β
Ye Ming smiled slightly: "No problem." β
- The main reason why they chose to come by bullet train is that their robots are really unsafe if they are checked in, so they can only carry them with them.
What if someone gets rid of this thing or breaks it...... Then everyone can't even find a place to cry.
Then, just as he looked at the box under his seat, he also saw the mains outlet next to his seat.
Ye Ming blinked and touched the backpack on the side.
- What he said to Shen Ruhai was that he brushed hundreds of ways.
Is 130 a few hundred?
Apparently not.
Then go ahead.
He's going to be a big brush today.