After interviews with several companies, I finally came to iQiyi (Shanghai), where I worked in a field that I am very interested in. To get this result for two and a half years into the industry & non-training for the author is no doubt lucky.
I am very grateful to the interviewer for giving me this opportunity, because not everyone will recognize your efforts, and nothing should be taken for granted.
The specific face of which companies, which interview questions here do not share, because the sense of reference is not very big.
- Which companies are not convenient to be disclosed here.
- The interview questions of these companies are not very different, mainly need to pay attention to the quality of the answer; Moreover, even the same interviewer may ask different questions to different interviewees, because he or she may ask some unplanned questions influenced by the answer of the interviewees, which I have experienced when I was an interviewer.
In the next article, I will give you a set of interview questions that I think can be used to interview advanced iOS
This article is about how I prepared for an interview at this stage. Everyone may have their own learning methods, the author’s method is not very efficient, but still hope that you can have a certain reference.
To prepare the interview
There are three main ways to prepare for an interview:
- Tools used
- Organize the interview questions
- Time management
Tools used
The two most frequently used tools in preparing for an interview are:
- Youdao note
- Wonderful listing
1. Youdao Notes
- Purpose 1: Used to collect knowledge sources: Youdao note browser plug-in can quickly save web pages with one key, but also can collect the articles of the public account.
- Use 2: To organize the interview questions: support multi-level folder, can clearly see the knowledge structure; Support for MarkDown, which can save code.
The process of organizing notes is the process of understanding, and repeatedly chewing your notes can help you understand.
2. Magic list
- Use 1: It is used to record the problem points that suddenly come to mind: sometimes a question may pop out in the head, but the answer can not come up immediately. At this point, you need to save it in a familiar location.
- Use 2: List the interview questions you haven’t solved so far: it gives you a better idea of how much work you have to do to finish your review.
Lists are a tool to free up the brain, because the brain is for thinking, not for remembering. Put the things you need to think about in the first place, let the brain out ~
Another big advantage of both tools is that they are cross-platform: both support (Mac, Windows, Android, iOS) and sync well. So they can be updated at any time when it is not convenient to use the computer, especially when you have a good idea can be immediately written down on the phone.
Organize the interview questions
Classification of Interview Questions
The author tried to collect all the online iOS interview questions, from the lowest difficulty to the highest, of course, there are also some articles introducing certain knowledge points. After summarizing these questions, the author divided them into several topics and put them in youdao Notes:
- IOS basics: e.g. “How does KVO work?” And so on.
- IOS word questions: e.g. “There are several reasons for crashes and how to avoid them?” And so on.
- Block: for example: “What’s the difference between a primitive type variable and an object that is __block or not?” And so on.
- RunLoop: for example, “What can be done with RunLoop?” And so on.
- Runtime: for example, “What happens between receiving a method from an object that it cannot respond to and crashing?” And so on.
- Network: for example, “HTTPS handshake process?” And so on.
- Multithreading: for example, “How many strategies are there for thread synchronization? What kinds of locks do you know and the difference between them?” And so on.
- Computer systems: for example, “How many areas and functions of memory?” And so on.
- Design patterns: “What design patterns are practiced in the iOS SDK?” And so on.
- Architecture: for example “What’s the difference between MVVM and MVP?” And so on.
- Data structures: for example, “How do hash tables work? How do you resolve conflicts?” And so on.
Algorithm problem preparation
Finally, let’s talk about the algorithm: the author because there is no algorithm basis, and the time is relatively tight, so only prepared array, linked list, binary tree algorithm, language is C++. The main sources of these questions are the topics above “Sword Point Offer” and “LeetCode”. I learned them for about a month in total.
I’ve put the algorithm I’ve learned on my GitHub library (with answers, and they’re all correct) : awesome-algorithm-question-solution. The algorithm questions in this library are mostly the algorithm questions often tested in mobile interviews.
Currently based on C++, interested students are welcome to submit answers in Java and Swift.
The relevant books
Here are some books you can use to prepare for an interview:
-
IOS based
- Effective Objective-C: Introduces some of the specifications and techniques of objective-C development. I wrote three articles about the book:
- Effective Objective-C Dry Goods Trilogy part 1: Concepts
- Effective Objective-C Dry Goods Trilogy (Part 2) : Specification
- Effective Objective-C Dry Goods Trilogy (Part 3) : Tips
- Advanced Programming in Objective-C: Memory management, Block basics, GCD. I also wrote three articles summarizing the book:
- Advanced Programming in Objective-C (Part 1) : Counting references
- Advanced Programming in Objective-C: Blocks
- Advanced Programming in Objective-C: A GCD
- Effective Objective-C: Introduces some of the specifications and techniques of objective-C development. I wrote three articles about the book:
-
network
- “Graphic HTTP” : explains the HTTP related knowledge, easy to understand.
- “Illustrated TCP/IP” : explains TCP/IP related knowledge, style and “Illustrated HTTP” similar.
-
Design patterns
- The Way of Objective-C Programming: An Analysis of iOS Design Patterns: This book introduces design patterns used in the iOS SDK, combining theory and practice, and is one of my favorite books. This book will be easier for those of you who are familiar with iOS. It is not recommended that the foundation is slightly weak, business scenarios encountered not many students to read this book, because it will be very obscure.
-
Data structures and algorithms
- “Sword point Offer” : this book is not very difficult, if there is no basis, you can pick a few feeling is relatively simple algorithm based on array to learn. And this book also introduces some of the interview algorithm questions some skills and need to pay attention to the place (commonly known as routines). You don’t even have to look at the algorithm here.
- LeetCode algorithm questions: If time is tight, you can directly see the author above GitHub warehouse (Awesome -algorithm-question- Solution), because most of these are mobile terminal more commonly tested algorithm questions. However, there is no guarantee that the performance of the algorithm will be the best, because improving the performance of the algorithm also requires some time and cost to learn. Here, only moderate performance is guaranteed, and the output is certainly correct.
In general, if you are pressed for time, it is recommended that you first read some tips on algorithmic interview “routines” in Sword Point Offer. Then go straight to the subject, find some often tested algorithm problems to learn.
-
Knowledge of computer systems:
- “The Self-cultivation of programmers” (Yu Jia-zi, Shi Fan, Pan Ai-min) : The first chapter of the process, thread safety, various locks explain better. The latter part is a bit deeper, so you can skip it if time doesn’t allow.
Time management
A good time management strategy can help you keep your plan on track. Here are two points to introduce the author’s time management strategy:
- What do you do every day
- What not to do
What do you do every day
Because I was working at that time, I had limited time to prepare for the interview, but I allocated a fixed proportion of time for different knowledge points every day:
-
Type 1: new knowledge. This kind of knowledge is to read every day, because for new knowledge needs time to digest and absorb. The allotted time is about half of the total study time of the day.
-
Type two: unfamiliar knowledge. This kind of knowledge points to those new knowledge points that just understand good or more difficult to understand, need to look repeatedly and digest knowledge points. About half of a day’s study time.
-
Type three: very familiar knowledge. This part of the knowledge belongs to a more thorough understanding, but also need to take time to review, is this part of the time is not very heavy, simple glance can be.
In addition, it also costs to allocate the time to organize the knowledge points: for the above three knowledge points, in fact, need to repeatedly organize and absorb, try to express it with their own words, the time ratio is not very heavy, but it is very useful.
What not to do
In terms of time management, I personally agree with the idea that knowing what not to do is more important than knowing what to do. Because people’s energy is limited, there are only 24 hours in a day, when something is important, other things have to make a concession.
I gave up a lot of things in the first half of this year to prepare for my interview:
- My gym membership is about to expire, but I haven’t been there once.
- Classmate, family reunion also declined politely.
- I haven’t played chicken. I haven’t been to the movies.
Frankly speaking, AFTER I got the offer, I went to the gym, had a get-together with my classmates and family, and met my old friends. They also expressed a comparative understanding, so I also feel quite gratified.
It is not difficult to find a job, but it is very difficult to find a job that is most suitable for you at present. I hope you can make some choices, make a good plan and put it into practice. There should be good results.
After briefly talking about this stage of the interview experience and the methods and strategies to prepare for the interview, here is the author of some of the ideas of some peers want to say. Because these also include this first half of the interview others and oneself go to the interview experience, so here and interview experience said together. It might be a little subjective in some places.
I want to say something about some of my colleagues’ ideas
“The industry is down”
You hear this once or twice a month. In the first half of this year a lot of friends in the interview, maybe because some friends are not very smooth, feeling and hair. In addition, I was also hiring for the company in the first half of this year, and I had a feeling that it was very difficult to recruit senior iOS developers. Although it has been 3 or 4 years, I have little knowledge about design patterns, data structures and the underlying aspects of iOS. I have only seen SDWebimage as an open source library (maybe I just read the analysis on the Internet). In short, I have not met my personal requirements for an advanced iOS development.
But on the other hand, I also heard that many people went to great companies, such as Toutiao, BAT and so on, and their ratings were high.
Personally, I don’t think the industry is in a slump, but rather that many developers are not in a state of continuous learning. Instead, they just repeat one year of experience for many years, and end up with their abilities below the standard for their years.
I think since as a software developer, we should constantly break through themselves. For front-end developers, learn as much as possible about generic knowledge outside of the UI level, such as data structures and algorithms, network protocols, design patterns, and look at some good open source libraries. Here are some of my previous source code parsing blogs:
- YYCache Source parsing
- YTKNetwork source code parsing
- MJRefresh source parsing
- VVeboTableView source parsing
- PNChart source code analysis
- SDWebImage source parsing
“It’s hard to get an interview because I don’t have a good degree.”
This is what I hear a lot from my peers who are familiar with me, who feel that their opportunities for an interview are limited by their academic qualifications.
But there are a lot of things that appeal to a resume: a good blog, good Github code, good project experience, deep technical sharing, etc.
There is a quote I like very much:
Alter what is changeable, and accept what is immutable
It means to change what is changeable and to accept what is unchangeable. Since the degree is hard to change, then accept it, do not complain about it, do not use it as an excuse, should focus on the things that can change:
- Blogging: It’s easy to build your own blog these days, there’s a ready-made framework (Hexo), it’s cheap to learn, and if you have the skills you need, you can do it here.
- GitHub: I don’t need to talk about this, but if you encapsulate components that work well, you can put them on top, keep updating and optimizing, and show personal growth. Even better, get involved in a large open source project.
- Project lesson: This may be out of your control, but you can make a feature point the best you can, right?
- Technology sharing: If you work on a new technology, can you share it with your colleagues? At the same time, you can exercise yourself.
Personally, I pay more attention to one and two points: from these two points, it can be seen that the person’s pursuit of technology, whether he is keen on sharing, whether he has good expression ability and ideas. However, due to more objective influence on 3 and 4 points, the author does not pay much attention to them.
I read a study that showed that developers with higher degrees and better schools tend to produce more on GitHub and blogs. This is a good question to think about, but it also suggests that developers with less advanced degrees and schools should pay more attention to GitHub and blogs.
“[Big companies] interview to build rockets, work to screw.”
I’ve heard this a lot, and I can tell that most people say it in a slightly negative way.
I personally believe the hiring of a major corporation strategy is very reasonable, because now that is a big company, is rich in resources, either it is rocket, or ready to build a rocket, so people must be for those who have the ability to build rockets or is the basis of the training can be made after the rockets better people. And great oaks from little acorns, not everyone around the design of the discussion, right? Every man has his duty, and what general did not start as a soldier?
So we should treat this matter with the right attitude:
- If you really want to enter a big company, then sharpen your head, well prepare the bottom knowledge and algorithm questions to fight for: get the offer is the best, even if you can’t get it, there will be harvest, after all, you have worked hard, you also personally experience the requirements of a big company.
- If you really don’t want to work for a big company, try not to think about it, and don’t spread negative feelings about it.
- If you are not sure if you want to go to a big company, then it is best to set the direction now, the direction will have a plan, plans will have results.
“I haven’t encountered this part of the job, so I don’t know.”
I also hired people for the company in the first half of this year. This sentence is often heard when I am an interviewer, such as “what is the difference between NSSet and NSArray”, “what is the reflection practice of iOS?” When asked this question, interviewees often excuse themselves for not having done it.
In fact, I think the above two knowledge points and did not do the corresponding business is not too direct relationship (I myself in the actual project did not do).
- For the first question, if you’ve studied hash tables, and by the way, the iOS SDK implementation, or if you’ve researched any collection classes other than arrays and dictionaries, you’re going to come across NSSets. Or if you look at AFNetworking’s source code, you can access it.
- On the second question, if you know that Java has the concept of reflection, then you can explore iOS reflection by analogy and see that it can be implemented using some runtime functions.
Therefore, no matter which language to learn, if the realization of the knowledge can be explored from some general knowledge points, it will be more helpful to deepen the understanding of the language itself, and also improve the corresponding business ability:
For example, if you just need a set, and you just want to determine whether the elements are in it, you just use NSSet; But if you don’t know that NSSets exist, you’re probably just going to do it with NSArray, because array queries are much slower than hash tables.
Therefore, the most afraid of learning is not knowing that they do not know: more contact, more exploration is always good.
“I’m not a student, so I don’t know data structures and algorithms.”
When I was an interviewer, I found that there were not many people who wanted to actively learn data structures and algorithms in non-professional groups. Because every time I ask some knowledge about data structure and algorithm, I will always hear that I am not trained as an excuse for not knowing this kind of questions.
I think if you want to write a program on the road to go far, this piece is certainly not around the past. There is a formula:
Program = data structure + algorithm
A good program is often inseparable from both. This means that if you want to write a good program, you need to choose the right data structure and algorithm (or at least the right data structure).
For example: now you need to use a collection to hold names and provide an interface to determine if the names passed in are in the collection. So if you were to implement this function, the data structure of the collection would you use an array, a dictionary, or a Set?
If you don’t know the advantages of sets, you’ll probably do it with arrays (judging by the index returned). But the time complexity of an array query is O(N), which is much less than O(1) for a Set, so this shows how much performance can be helped by using the right data structure.
I am not a professional, but after learning data structures and algorithms, I found that MY ability to design functions and understand code has been greatly improved. As mentioned above, the author has only mastered 30 to LeetCode questions and some basic data structures. So I hope that you can also make a good plan for this piece of study. And some of the students of the training background, precisely because they are the training background, so after work, they did not take the initiative to improve this knowledge, so the students of the non-training class should take the initiative to plan their own, with the fastest speed to fill their own loopholes.
Above is the author this period of time some thinking and idea.
This summary is written here, a total of two parts, I hope you can learn something, also very welcome to communicate with me ~
This post has been synchronized to my blog: iOS interview Tips for 2018
The author recently opened a personal public account, mainly to share programming, reading notes, thinking articles.
- Programming articles: a selection of my previous technical articles, as well as subsequent technical articles (mainly original), will gradually move away from iOS content and focus on improving programming capabilities.
- Reading notes: Share your reading notes on programming, thinking, psychology, and workplace books.
- Thinking articles: share my thoughts on technology and life.
Because there is a limit to the number of messages published on the official account every day, so far we have not published all the selected articles in the past on the official account, and will be published gradually in the future.
And because of the various limitations of the major blog platform, later will be published on the public account some short and concise, to see the big dry goods articles oh ~
Scan the qr code below and click follow, looking forward to growing together with you ~