Call a preliminary

Three days after I was told my resume had passed the review, I received a call from Shanghai. On the other side was a little brother, who briefly introduced himself as ali’s and asked if I had time for a simple initial phone interview to see if it was appropriate to initiate a follow-up process for a formal interview. I said yes at work and quickly ran down the hall. I felt a little regret, because it was a cold outside, I did not put on my one thousand yuan warm coat, and embarrassed to say back to the station to wear clothes, so the whole journey in the shivering.

At the beginning, I was asked to make a brief introduction of myself, asking me where I was working, why I was leaving and what projects I was working on. Then let me pick a recent project I’m working on and talk about the tech stack. I took a project that I was building and went on and on for about four or five minutes about the background, the staffing, the technology stack. Then my brother asked me why I chose this technology stack, and I said that I felt I was suitable and initiated a formal interview process for me. As soon as I heard that, I couldn’t wait to launch the process! Then my little brother asked me if I had any questions to ask him. Because it was too cold outside, I asked a question. Could you introduce the business of your department? The interview brother from his own department, to the prospect, and then to the job content to introduce me clearly, said that There is a position in Beijing, but will first go to Hangzhou to work for half a year to a year, and finally said that he would contact me in a week for an interview. As it was too cold, I asked no more questions, and so happily ended!

There’s nothing wrong with this step, just open up and talk to the interviewer. Ask him or her what you want to know. Tell him or her what you want to know.

Round technical surface

As I told the interviewer that I was not in the same city as him, and I was currently on the job and could not go to the on-site interview, he readily agreed to the video interview. About three days later, I received another phone call from the younger brother, who wanted to arrange an interview with me. I asked if it was possible to arrange an interview with me in the evening, but the younger brother readily agreed. By then, I had learned that Ali also worked in the evening, which was the same as I do now. We agreed to the time, exchange aspirations, meet be there or be square! To the appointed time I will think of the little brother said that he would give me a video interview, I came mengbi, since it is a video interview is QQ video, wechat video? Still wondering I was interrupted by the ringing of the mobile phone, I looked or familiar with the number, or familiar with the feeling, as expected is that lovely little brother. Little brother asked me if I was ready to start the interview! What? My younger brother turned out to be my interviewer. I always thought he was HR’s younger brother. Before I asked him clearly, he said he would send a link to my email. May be the arrangement of more people, a time can not find my email, said you first to introduce myself, at this time I am disheartened, is not just know, are already so familiar with the need to introduce myself? Have you forgotten him already? When I’m sad, I found that time has passed for three seconds, so I began to introduce myself, this time to introduce myself more detailed than before, mainly personal basic situation, the ability to work and future plan of three ways, after introducing myself to finish the little brother said to have an idea of lad, I send you a link to the mailbox, you go and see. It took me two seconds to get to my email and open the link. My handsome face appeared on the computer screen and I saw the interview! Wow, just as handsome and handsome as me. Anyway, I’m ready for the interview.

Suddenly my avatar shrank, and the familiar text box appeared on the screen. Yes, you guessed it, live code! The first question is about regular matching. It’s not difficult, but you need to consider the boundary case, because it’s too easy, so I won’t post it.

It took about a minute to finish, and then he was satisfied to tell his little brother that it was done. He looked at my results and immediately came up with the second question:

Specific topic due to the time too long did not remember too clear, is an array operation topic, temporarily to the current most popular array to redo as an example, this topic focuses on the js array to master, can not use ES6 syntax.

Get this problem I feel very simple, so began the normal sorting, to heavy. Here’s my first try

function merge(arr) {
  if(! Array.isArray(arr) || arr.length == 0)return [];
  
  arr.sort();
  
  var ret = [arr[0]];
  for (var i = 0, j = i + 1; j < arr.length; j++) {
    if (arr[i] != arr[j]) {
      	ret.push(arr[j]);
      	i = j;
    }
  }
  
  return ret;
}
Copy the code

I opened the console and pasted my code as fast as I could. I found that the result was wrong. What happened? Only to find that because the order is changed, can not be sorted. Again my second attempt

function merge(arr) {
  if(! Array.isArray(arr) || arr.length == 0)return [];
  var ret = {};

  for (var i = 0; i < arr.length; i++) {
  	ret[arr[i]] = i;
  }
  
  return Object.keys(ret);
}
Copy the code

I found that this can indeed go heavy, but the order also followed the change, how should this be good? Then the little brother said, is this problem difficult? I immediately said it’s not difficult, I shouldn’t sort, and then he said you don’t need to sort at all and you can use ES6 syntax. What? This question is not examining the algorithm but the ES6 syntax, killing me I also do not believe, this is clearly an algorithm… In the span of one tenth of a second, my second pulse was suddenly opened, and I did not complain, but as fast as I could for my third attempt

function merge(arr) {
  if(! Array.isArray(arr) || arr.length == 0)return [];
  var ret = [];

  for(var i = 0; i < arr.length; If (arr[I] == -1) {if (arr[I] == -1)if(arr.indexOf(arr[i]) == i) { ret.push(arr[i]); }}return ret;
}
Copy the code

Haven’t finished writing, little brother synchronized to my idea, smooth pass! By the way, there’s also a code that can do this:

[...new Set(arr)]; // Array. From (new Set(arr)); // Thanks for the comment section, I came up with a one-sentence solution, including filter. Here is another abnormal solution, please accept (arr +)', ').replace(/(\d+,)\1+/ig, '$1').split(', ').slice(0, -1);
Copy the code

Here is a look at the ES6 API, and then give me a third question

Implement the Currization of functions

It’s a familiar recipe, so I started trying it out

function composeFunctions() {
   var args = Array.prototype.slice.apply(arguments);
   
   var _func = function() {
        if (arguments.length === 0) {
            return func.apply(this, args);
        }
        
        Array.prototype.push.apply(args, arguments);
        return _func;
    }
    
    return _func;
}
Copy the code

Above is my first try, because I was the wrong parameter, which is the last Array. The prototype. Push. Pass the apply that wrong parameter debugging anyway, and you won’t come, I feel my train of thought, yes ah, why wrong result, is planning to open the debug tool to debug, little brother began to talk, Is it difficult to ask me this subject? Of course I said it wasn’t hard, not for the rest of my life. And then he started to help me analyze it, and he said how can this problem return a function? I… Emm? I said yes, should not return the function, at this time estimated that the little brother realized that I took the side, so quickly said is to return a function ha, I… Emm (fear of being dominated left me in tears without technology)? At this point I have no words to express my embarrassment. He asked me what the problem was. I said I felt it was all right, but I couldn’t get it out of my head, and THEN I saw him reading my code, and I said ok, let’s get right to the interview! There were four questions, but I think you should do three!

Foreplay takes about 15 minutes, and then you get straight to the point.

The first question is the age-old question of how to use CSS to achieve horizontal and vertical centering. I have used six implementation schemes, among which the last one is based on vertical-align and text reference line. Interested partners can find this scheme by themselves.

The second question is how promises are used and how they are implemented.

The third issue is front-end storage, and the pros and cons of each.

The fourth question was about the solution for page adaptation on mobile terminals. I answered that Taobao’s flexible. Js was used for screen adaptation, and the interviewer asked about its implementation principle and the characteristics and differences of several length units (REM, EM and PX) in browsers. I didn’t fully understand the difference between physical pixels and logical pixels, and the interviewer also told me that it’s more interesting to understand how a framework works than to use one, right?

The fifth question is the difference between React and Vue and the implementation principle. Besides, what is Fibber in React? I only know Fibber is scheduling, which can improve the efficiency of React rendering, but I don’t know the specific implementation principle.

The sixth problem is the JS Event Loop.

The seventh question was three handshakes and four waves.

Finally, he asked me about the project with the most sense of achievement recently, and introduced the technical solution of the project. What makes you feel unique sense of achievement, and what are the difficulties you encounter and how to solve them?

Finally, the interviewer made an evaluation of me, saying that I know a lot but my expression is not very smooth, so I should pay more attention to it in the future. I repeatedly reached good good! After that, do you have any questions you need to know? I asked them two questions. The first one was their definition of talent. What kind of person do they want to hire? The younger brother smiled and said that this question was too big, and immediately asked me to give me a definition of talent. In fact, I just want to know how I perform today, so I asked this question, so I said my talent concept, and then he explained his point of view to me. When will I know the result of the interview? He said a week at the latest, which I later found to be a common refrain of all interviewers who, when asked, will have a decision within a week. In the end, I finished the interview happily. Generally speaking, I was relaxed.

Second round technical side

About four days after the interview, I received a phone call from Hangzhou, telling me that I had made an appointment for a second interview and exchanged wechat messages with the interviewer for the second interview. Later I found out that the second interview was the boss I was chatting with above a boss, technical expert level! I wait with uneasy mood to accept the second face, because the second face is responsible for the department.

After all, the interview came. When I saw the call from Hangzhou, I couldn’t wait to be connected. When I heard the accent, I felt that the interviewer was very nice. First of all, I made a self-introduction and then began the formal interview.

In my self-introduction, I briefly introduced my current business, and the interviewer asked me to pick the one I was most familiar with and talk with him about specific technical solutions, problems encountered and solutions. For the first ten minutes or so it was pretty much my project, and everything went well. Then I asked a few questions about TS. I asked if I had any questions. I didn’t know what to do, because the whole interview went well and we had a great conversation. Do you feel good about yourself and bad about others? Although there were a series of questions, I only asked one question, that is, a problem I met in the work of the company that day. He first smiled and then asked me how I solved it. After I finished talking, he put forward his own opinion. He said that he appreciated my way of doing things very much. The feeling of being praised by the interviewer for the first time was overwhelming! Then tell me how he would solve it if it were him, big guy really is big guy, I sighed silently! Then the second interview ended.

Three boss

After the end of the second interview is a long wait, wait for ten days time has not contacted me, I think it should be kneeling. Because I have one interview, the second interview, so I tentatively asked the second interview of my situation, he said you passed, but the boss is busy recently did not have time for the interview, so it took so long, wait patiently! I was flattered and determined to prepare.

Two weeks after the second interview, I finally got a call from Hangzhou. As expected, it was Ali HR who made an appointment with me for the video interview on the weekend. And told me that the boss was busy and must not stand me up.

The night before the final meeting, HR sister called to say that the interview time needs to be adjusted, because the boss had a temporary meeting, so it was postponed for five days.

The interview was on a working day. I asked for leave and went back home. Although the first two sides went well, THE third part was still very nervous. Ali’s internal conference system was used on the third side. When I arrived at the specified time, I connected it and got no response. The line was busy when I called HR. I saw a total of two people, one is a legendary boss (male), the other (female) did not guess what position. Ask briefly and get to the point.

First, let me introduce myself and then ask me what I do in JINGdong. I was like, what am I doing? What am I doing? After two sentences of introduction, boss then asks, what is the product XXX you are talking about? After a brief introduction of the product, the boss looked up at me and said, “I have no more questions.” Then he looked at another interviewer and asked, “Do you have any more questions?” Another interviewer asked me why I was leaving. I said I wanted to work on a better platform. Then I said that my intention was to apply for a job in Beijing, but they were in Hangzhou. I said that HR told me that THERE was a job available in Beijing, and the interviewer told me that I had to work in Hangzhou for half a year to a year before I could go to Beijing. I said there was no problem! Do you have any questions?

I asked three questions. The first one, again, was to find out what they meant by talent. The answer was that it was too big. The second question is what’s next for the front-end, from Ajax to Node to data-driven? The boss looking at the phone looked up at me and said, “Sorry, I’m not in the front end, you change the question!” I address my third question: When will the results come? I got the answer in a week, and then I said that’s it for today, and I’ll call you later. A face meng forced in, a face meng forced out, so the end of three.

As I asked for leave, I went straight to the company to continue my work after the interview. As soon as I sat down, I received an email notification from Alibaba. I thought I passed, but as soon as I looked at my resume, I was directly pushed to Ant Financial! It means CBU process is over, my resume is released, which means interview kneel. I was so frustrated that I cut a picture and sent it to my interviewer. He said he would help me ask the boss what was going on. I was quickly told that the reason for the failure was the complexity of the project. He constantly consoled me that it was normal and the passing rate of the interview was very low. He told me not to lose heart because the interview was very lucky. In addition, he told me that the first and second interviewers felt it was a pity, but there was no way. Let me try other departments. Thank you again for the lovely little brother of the interviewer who helped me throughout the whole process! Although very frustrated, but after the interview summary is essential.

The interview summary

Compared with other companies, I found that the questions I was asked during the interview with Ali were not very difficult. Ali paid more attention to the foundation rather than just staying at the stage of knowing how to use it. So at ordinary times to look at good open source projects, look at the basic content, more understanding of the underlying implementation principle.

As for the questions asked by the boss, I concluded that they were both huge. First of all, what are you doing? Actually asked the implication is that what you have done projects, at the moment is the right thing to introduce yourself in the role of the project, all project, and then in detail you participate in the technical scheme of project, the problems in the development process and how to solve these problems, the initiative completely over to you, you are free to play the interviewer into your mind. In fact, the interviewer is more interested in how you solve the problem, rather than how I solved it in two sentences. The second question is to introduce your product in detail. What are the advantages of your product and other competitive products? What you’ve contributed and what you’ve accomplished so far. This kind of open question is good or good answer, not good answer is not good answer, completely depends on their language organization ability.

Ali has always been the company I want to work for, and it is also among the top Internet companies in China. Therefore, it is not easy to enter, in order to successfully enter Ali in addition to excellent technical foundation, but also need to have good expression ability, handling skills and other soft power. One failure is nothing. It is important to sum up carefully and not deal with the same problem in the same wrong way the next time. With pesticides inside the cheng bite gold, anyway, you hit me, not to accept to hit me!