The most important words are written in the front: this article does not allow any public account, forum community, micro blog reprint. See the beginning of the previous article for reasons.
As mentioned above, my interview method has evolved in three stages. Here is the last stage.
Stage 3: Write code on the spot
From the beginning of the interview process, the idea of having candidates write code on the spot crossed my mind. After all, as a programmer, the quickest way to know how good you are is to look at the code (so I have sent all the CVS with github links to them, and there are only two of them). However, I always hesitated and did not adopt this method at the beginning. The main reason was that I was afraid that the interviewees would be tired. Because writing code is always tiring, especially if you’re writing code in such a short period of time. When I went to the next company on my own, several rounds of interviews took me three hours of coding, and I was so nervous THAT I doubted life. The candidate may have an interview with another company on the same day. I am afraid that I will be too tired. Another reason is that it takes a long time to write code, and there are too many interviewees. The boss asked me to pass each one in 40 minutes. What can I write in 40 minutes?
But one gentleman made me decide to ask the people in the back of the interview to write code on the spot, even if it was just two or three lines. I was still working on stage two questions, and I asked, “What do you feel are the difficulties with development?” He replied, “I usually work on drawing interfaces, so I don’t feel difficult. One time it was a bit of a hassle to do landscape, because the general requirement was portrait, only one screen was landscape, and then the keyboard had problems…”
I think this answer is reasonable, because the single screen landscape is a bit of a hassle. Another question: “What refactoring have you done?” The answer was, the previous company used the outsourcing code directly, MVC layer is not clear, a viewController has thousands of lines, a lot of drawing code; He tries to separate the UI drawing into a separate view. I nodded as I listened. When I graduated, the leader took me to do something similar. I have a good impression of the interviewee so far. Then I talked about the controls I had encapsulated. I asked casually: “When do I use weak?”
“Weak…” was the reply. Weak is usually used to describe an int or something.”
The answer was unexpected. Weak int I think it might be a small slip of the tongue, just in front of the computer, I said: “Weak modify int will definitely report the wrong.” Knock out, as expected that line red.
But the other just froze. One minute of staring silence.
By sending this gentleman away, I again had deep doubts about my interview skills. How can an engineer who has worked for three years and refactored thousands of viewControllers not know that weak cannot be used to modify an int? This experience was a wake-up call for me: the general questions used in the second stage, such as “what difficulties have I encountered in the work”, are much more pleasant to talk about than the knowledge questions, but they have the weakness that they can be prepared in advance. Perhaps the interviewer will first consult friends who are experienced in development, memorize their answers one by one, and prepare a perfect set of speech. If you go to a company where no one knows iOS, they might be assumed to be great and experienced; If I hadn’t asked the question casually, I might have let him go, too.
I decided to have each candidate type as many lines of code as possible. Make sure you hire at least one person who can write code…
Now that you’ve decided to write code, what’s the title? I think is the package of a simple small control will be better, the final choice is the bulletin board, is the text up and down automatically scrolling round broadcast. Similar to the text scrolling behind “Jubao Toutiao” on ant Financial home page, the content can be made into a line of label, stop for 2s and scroll once. You just scroll in one direction, you don’t have to drag it with your fingers. Click to trigger the click event, hit a log.
I choose their own problem or more satisfied, the difficulty is not big, at the same time can investigate the point is many. When I set the question, I would first show the interviewer this small control I implemented in my own app. On the one hand, it is to explain the question more clearly, so that the other party can think while looking at the example, which is helpful to think about how to achieve it. On the other hand, in order to prevent people from misunderstanding, we use the interview to trick the code, trick them to help me work ><
While the functionality is simple, the code takes time to write. What I tell the candidates is, 30 minutes to write anything, the computer is over the wall, you can look up anything online, you can write as much as you want, it doesn’t matter if you can’t finish it, let’s look at the code. Of the eight candidates who did this, two were 90% successful, and half had no idea how to do it until the time was up. In fact, as long as you can write a prototype, can dictate how to write the next, I have given everything.
I still feel guilty about actually asking candidates to do the hard work of coding on the spot. Therefore, FOR each candidate who wrote the code, I will review them line by line. I hope they can get a little gain while spending all the time and energy. This is the only way I can compensate them.
Speed and coding specifications
Speed, because the time is really not enough, so as long as the idea can, does not require much code. I admired the quick engineer who wrote over 100 lines of code in 30 minutes. There are also engineers who are slightly too slow. They only wrote less than 10 lines of code in 30 minutes and drew two labels without having time to think about the following ideas. This kind of situation can let a person unavoidably worry about his later development speed, so can not pass directly.
There was one candidate in particular. I will introduce myself first, and then ask each other to introduce themselves briefly. In fact, one or two sentences can be used, and 3~5 minutes are normal. But she talked for 20 minutes about how the company did business and how it was run in a non-technical way, and there was no gap. I couldn’t find a chance to interrupt. Asked to do the problem, he immediately said that there must be a third party implementation. I said don’t get a third party, try to write it yourself. Half an hour later, he came back to find that he had uploaded a third-party implementation from Github and put it into the project. I am not too happy, into the third party source asked him a few details, as expected he did not have too deep consideration. If in the project development, find open source implementation of course no problem, although I think this simple control to write their own problems less. However, in the interview, I clearly said that I wrote by myself and insisted on using a third-party library, which inevitably made people think that I was not confident in my development ability.
In terms of coding specifications, it’s interesting to see what people do differently. Some friends do not love space, equal sign, plus or minus sign on both sides are not space; Some names mix hump and underscore; Others use only instance variables instead of properties. Of course, whatever personal habits you may have, I think you can treat them with tolerance and avoid criticizing them. But the code is more in line with the popular specification, the name is easier to read, look at the time must be more favorable ~
How to achieve rotation effect on UI
In fact the most simple implementation is two label circulation, one on the top roll out then back into the bottom of the screen. But in fact, we think of a variety of solutions: there are several people want to use UITableView, UICollectionView, useful UIScrollView, each label on the row. I don’t think it matters which one you choose, it’s not a big deal to use scrollView without reuse, as long as it works. But the idea is basically to line up each line of text from top to bottom, and then start on the first line and scroll down. This leads to a common problem: What about the last line?
One engineer had the idea to copy the first line of text to the last; I think it’s very clever not to scroll back to the beginning after the last line. But everyone else either has no idea, or just clattered back from the last line to the first. It seems that the effect is not good enough, and I think it is a problem that should be considered at the beginning of design.
By value
Because requiring click events on labels addresses one of the most basic problems in development: how to pass click events out. There are not many people writing here, mainly questions + dictation, and I find that people still like to use block more now. One of them wrote a delegate in earnest:
@protocol ScrollLabelDelegate <NSObject>
- (void)scrollLabel:(ScrollLabel *)scrollLabel didSelectIndex:(NSUInteger)index;
@end
@interface ScrollLabel : UIView
@property (nonatomic, weak) id <ScrollLabelDelegate> delegate;Copy the code
Write very standard, once conquered me ~
Here’S a quick question: “If you’re going to use a delegate, what keywords are used to modify the delegate property?” All three interviewees answered simply, “Assign.” I explained to them why weak was better than assign, guessing that they might have watched the same outdated teaching video and left the same wrong impression. Although delegates are used relatively sparingly in development these days, there are some basic things to know
Prevent memory leaks caused by timer
Something like timer, you might think it’s pretty simple, but you can’t remember it in the API, so you can just look it up when you use it. For this question, I am allowed to look up any information on the Internet. As a matter of fact, the speed of experienced engineers is much faster than that of inexperienced engineers. One of them somehow spent all 30 minutes trying to start a dispatch timer and copied the code of his computer. In the end, the timer is still not activated…
There are several bits of NSTimer that save the timer as a strong property and then set the target of the timer to self. When I asked Timer if some APIS retain their targets, will it cause circular references? Is there a risk of memory leak? Most engineers said they hadn’t heard of it, with one replying, “It doesn’t matter, just set timer to nil in the dealloc method and release it.” But if you do have a circular reference, it won’t be a natural segue to the Dealloc method.
Recall the last article, some comments spray I asked the question is to install X, normal development anyway, it will not be used, with the time to check, what baidu can not solve the problem? I personally do not like that kind of very low-level, very partial interview questions, but also agree that many online interview questions are not used in normal development; But for this detail, it is essential that developers know something about memory management. If memory leaks are considered here, it’s easy to find a solution simply by Google “NSTimer Retain Cycle” with a bunch of results. But if you don’t know about it, you may not even realize it exists; Or like the friend who answered “breaking circular references in the Dealloc method,” assuming the problem has been solved. For those engineers, would they want to Google it? The end result is a hidden danger buried in the project.
Faced with the question “Is there a problem Baidu can’t solve?” Common problems really can not be solved, but the premise is to have a general concept. So although the last article was sprayed, I still plan to learn some basic knowledge after a period of time, even if I forget the details after reading, it is good to supplement the knowledge framework
The interviewer who impresses
About the interview experience, I can think of all without reservation to share with you. Finally, let’s make small talk about the candidates who impressed us
On the shortest interview ever
The interviewer who impressed me most was this one.
As soon as we both sat down, I said, “Hello, nice to meet you. Let me introduce myself: I am the iOS developer of this company. I have been working in this company for nearly two years. I start with the same opening line with everyone.
The other person interrupts me: “Is our company independent development?”
Me: “yes, but the company will recruit 1~2 people in June.”
There was silence.
Me: “Do you want to change jobs to find a non-indie developer?”
Person: “Yes.”
There was silence.
The other party: “that don’t we today first so?”
Then he got up and left. I was left dumbfounded.
Probably the shortest interview ever, hahaha. It was very generous and saved time for both of us. I really appreciate it. Since then, my opening line has been, “This position is independently developed, is it acceptable?”
About the training
Do iOS, the fierce training institutions are more or less heard. Some friends of the engineer out of the training of a vote, I do not have antipathy to the training institutions, our level of the company can not ask too much. The training itself is not the problem, the false resume is the problem. So I’m willing to go the extra mile for those candidates who say they are trained and thank them for their honesty. Unfortunately, these techniques are really not pass, do not know whether it is a coincidence.
Some of the resumes clearly show signs of forgery, like the 1995 kid saying three years of work experience. We screened out the resume, but somehow HR came to the appointment for us. Oneself explain is to have a relative how to exceed unripe yun Yun, cause oneself ID card age is small finally; Two years ago, although the training class was not particularly popular, he went out for an interview, but people did not believe him and said he was making it up… He said the same thing expertly. Two quick technical questions, delegate. I think it is not surprising, mainly because the previous explanation is too fluent, there is a feeling of sales, the feeling is not true.
There is a big brother impressed me deeply. He took out his resume, his education, degree, cet-4 certificate all printed out and attached to the resume, thick pile. Finally, there was a resignation certificate, which was covered with a red seal… During the interview, he put his hands flat on his knees, did not look at me, looked straight ahead, like endorsement, said: “MY name is XXX, 5 years of work experience, from XXX to XXX in XXX technology Co., LTD., XXX to XXX in XXX network company……” I asked him what code he refactored, and he said that every time I created a new view, I refactored the initWithFrame of the system. I felt very sad when I sent him away. My eldest brother was older, at least in his 30s, and he was a down-to-earth person who could not lie at all. Go to an interview like this, estimate no company can not see. To give up, and do not know how much savings and time he invested in training. This incident made me have a lot of bad feelings towards the training institutions. In order to earn more money, these people who are not suitable for the profession are tricked into coming in with their words and let them get into such a difficult situation and do what they have to do.
About sister
Two of the interviewees were female, accounting for less than one in ten. But their performance is good, technically all pass. One common feature is excellent communication and pleasant conversation. Although the final result is more regrettable, a sister for a long time serious overtime, no time to study, in the eldest pass; The other one has excellent technology and rich experience. Unfortunately, he wants to transfer to management. Maybe he feels there is no room for further development in a company of our size.
So in this case, I feel the girl is generally good technology, communication is also very advantageous. I hope they can find their ideal jobs. I also hope that the industry will be less biased and give equal opportunities to girls, believing that they can also bring matching contributions to the company.
About a good interviewer
The last article was sprayed, although I am very sad, actually think about it can understand. It’s easy to come off as patronizing and condescending by repeatedly listing your weaknesses.
But the real hiring process is much more than that. Especially when I met an excellent interviewee once in a while and chatted with him comfortably, I was deeply moved and almost begged him to come >< but the result was that he might not look down on us and leave. In this way, recruiting suddenly feels a lot like dating, a process of repeated disappointment and mutual hurt. It’s not just job seekers who can fail or fail, it’s recruiters who can too.
Probably the biggest reason companies get rejected is indie development. I mentioned that one engineer heard about indie development and left. There were two or three excellent engineers who went through the interview process politely, but later made it clear that they didn’t want to develop independently. This idea is quite understandable, because they are very good at technology, and both mentioned that there are no problems that can stop them at the daily level of development, and they may have reached the bottleneck stage of independent development; At this time, it is normal to want to have a more technically complex project, or to lead yourself. This may be the biggest difficulty for small companies in recruiting and retaining staff.
Even if we’re lucky enough to be liked, there may be all sorts of other reasons why we can’t talk. For example, HR may have some considerations of its own. There is an engineer who is very skilled and the boss is also very satisfied, but HR rejects it on the grounds of too frequent job-hopping and too many interests. Although I don’t know what is “too many hobbies” >< but I can’t help but worry about my job hopping every six months.
Another example is an engineer, I asked him to introduce himself, he a dejected, do not want to talk, did not introduce himself, just staring at the air, and asked me the working hours, overtime. Although he was not very polite, I reminded myself to try my best to be patient and smile and talk to him seriously. Unexpectedly, I met the most skilled interviewer in the entire recruitment process. I could answer all kinds of low-level questions as far as I could, and I could see that my level was above mine. Small control see a clear train of thought, I listen to do not have to let him write, directly over.
Despite his excellent skills, the interview was far from easy, and he listened to each question with a frown and an unhappy face, then answered in silence, punctuated by sighs. He admitted that he was exhausted and completely drained from working overtime at his previous employer. As expected, the boss said that he only talked about two words and then sent the person away, saying that he did not feel any passion for work, not suitable for the company at this stage of development. Of course, maybe they didn’t like our company either. Alas, or sincerely wish this brother to change a relaxed point of work, or take a holiday to relax, so go on really afraid of his depression… He has no problem finding a big factory with his skills, but it will be difficult to find any job if his mental state is not adjusted. Also remind the majority of code farmers, take good care of themselves, careful job burnout; If you feel that your work has drained you of all your energy, do more for yourself. It’s not worth sacrificing your health.
Finally, let’s talk about who we finally hired. In fact, when I saw his resume and his good company experience, I felt half at ease. Chatting really easy communication, excellent technology. Then I began to pray to myself, the boss gave it to HR gave it to the boss let him come, please… Fortunately, all the way back green light, in three days. I have been working for two weeks now, I am working very fast and I am very helpful. Thank god again and again that I can meet the right person and understand that all the hard work in front of me is worth it.
The length is almost the same as (above), but it is also very tired. Thank you for reading, to spray words for light spray, and do not reprint ha, afraid of being sprayed ~ finally, I wish you all can recruit satisfactory talent, find the ideal job 🙂