Interviews include: Ctrip, Ali, JINGdong, Tencent

During the National Holiday, the autumn recruitment is basically over, and there are a few interviews and a few procedures left. Although there is no final decision, but also decided to open a post, write some summary.

The building Lord is this year spring recruit of time start to see face classics, true topic do very few, very water =. = Be ashamed, be ashamed. Then, I was busy during the autumn recruitment, so I just applied for the official approval of the autumn recruitment. I either failed to apply or stepped on the line to apply, and I was not heard from directly.

The main iOS development, mainly using Swift language. Below some surface classics, hope to be able to have so little help to you.


Today’s headline

Spring recruit is the use of a wide net tactics (because at that time is completely a dish chicken, iOS most of the spring recruit side learning. It was also a fluke that I got the offer of toutiao summer intern, and then I decided to intern in Beijing by a strange combination of circumstances, and then I got the offer of full-time employment after the summer vacation.

At the beginning of the coincidence to the headlines, came to feel particularly good, ha ha, take the opportunity to recommend a wave. Internship salary (officially not yet discussed), benefits, department, location are all good, and I am still doing my internship.


ctrip

Ctrip is a very painful company.

Pushed inside cast Ctrip, passed the evaluation. Then, after a long wait, he called me one week and asked me if I could go to Shanghai for an interview. I said I was an intern in Beijing and could I have a remote interview. Hr readily agreed and appointed an interview two days later…

However, this was dove, into a long waiting period. Then send feedback to ctrip school recruitment group, finally got the interview opportunity, two rounds of interview feeling answer is ok, the question is not very difficult, but then suddenly gg.

Ctrip interview questions

One side

  1. Take a look at the code belowstatic int a = 1; int main(){ int m = 2; char *n = NULL; l = (char *)malloc(100 * sizeof(char)); return 0; }The efficiency of accessing variables of m, N and L is () from high to low.

    A. lnm

    B. mnl

    C. mln

    D. nlm
  2. Write a singleton
  3. Please write down the program calculation results AB two places are 1000 meters apart, Xiaoming from site A at the speed of 30 meters/minute to site B, xiaobai from site B at the speed of 20 meters/minute to site A, they start at the same time, write down in code how many minutes after they meet?
  4. Please write the output to the array [” – 12 of 12 “, “12-11”, “12-11”, “12-11”, “12-13” and “12-14”] to heavy sort at the same time
  5. Use a recursive method to calculate the sum of 99 to 1. Do you know recursion without trailing?
  6. Take a look at the code below
- (void)viewDidLoad
{
    [super viewDidLoad];
    dispatch_queue_t queue1 = dispatch_get_main_queue();
    dispatch_async(queue1, ^{NSLog(@"222 Hello?"); }); NSLog(@"aaaaaaa");
}Copy the code

A. Deadlock B. Print “aaaaAAA 222 Hello? C. Print 222 Hello? D.

Second interview

  1. Talk a little bit about the reuse mechanism of UITableView
  2. Tell us what you know about the Property field in Objective-C
  3. Tell us what you know about memory management in iOS. How is ARC implemented at the bottom?
  4. How do you encapsulate the network layer?
  5. How did you learn iOS development?

alibaba

My overall impression of Ali is favorable. In spring recruitment, I was very slow. I had an interview every two weeks and had to wait for nearly a month to send out offers. However, this autumn recruitment was very quick, I finished the three aspects in two days, both techniques were very fast, and they were all questions, so I felt that the total time was not as long as HR.

Ali interview questions

One side

  1. Why use Alamofire instead of native NSURLSession, and what are the advantages of Alamofire?
  2. If you had to package a web library like Alamofire or SDWebImage, how would you do it?
  3. In the network library, how to optimize the image rendering in the fast scrolling process of TableView (network library can not hold TableView)?

Second interview

  1. What is the architecture of iOS? What SDKS are commonly used?
  2. Do you know HTTP? What’s the difference between GET and POST?
  3. What do you know about security? How to deal with Web page hijacking? Do you know HTTPS encryption and decryption process

jingdong

Jingdong had a good experience on the whole, and I had a good conversation with the interviewers on both sides. The overall feeling is that all officers pay attention to the foundation, and two officers pay more attention to the project, basically according to the resume and project to ask. Then I get a phone call from three people (they said there were only two technical aspects) and then I get all kinds of things…

Jingdong Interview Questions

One side

  1. What is your understanding of iOS memory allocation? Value types and reference types?
  2. Suppose you need a Blcok in your ViewController to change a property in your ViewController, how do you do that?
  3. After that, where is the Block stored in memory? What about the reference relationship?
  4. A closure in a function that changes the value of a variable immediately after the closure is executed.
  5. How to achieve a similar wechat chat interface layout?
  6. %^&@$^@(#! . A lot of =. = use priority.

Second interview

  1. Talk about the differences between MVC and MVVM, and the pros and cons of each.
  2. How to transform MVC into MVVM? In MVVM, which module should the network request, cache handling parts be placed?
  3. Why is Swift a protocol-oriented language? What are the benefits of using Protocol?
  4. Compare Swift to Objective-C for language level security?
  5. What happens if you use weak to avoid cyclic references when using closures in a ViewController?
  6. What happens when you click on a View? How to expand the click area?
  7. How do I optimize my TableView?
  8. Can you explain your understanding of rasterization?

On three sides

  1. What do you think about Swift and OC?
  2. Can you explain your understanding of the optional types in Swift?
  3. What about quicksort pseudocode and time complexity?
  4. How do I know if two lists intersect?
  5. How do I reverse a binary tree?
  6. Know anything about tuples?
  7. Know anything about multithreading?
  8. What is parallelism?
  9. Now there are three tasks ABC, how to execute C after AB is completed?
  10. What do you know about Runtime?
  11. What’s the difference between HTTP and HTTPS?
  12. Do you know the HTTPS communication process?
  13. What’s the difference between Struct and Class?

tencent

The interview of Tencent really focused on the basics. Neither of the two interviewers knew much about iOS and did not have a deep discussion about the project. They just talked about the architecture of the project, which felt like they wanted to confirm whether it was done by yourself. After the first interview, THERE was no knowledge related to iOS, so I asked the interviewer whether I was in the wrong position at that time. =! In addition, Tencent HR’s attitude is really good, praise one.

One side

  1. Why Cache design? What are the benefits of Cache sizing?
  2. How to ensure the consistency of multi-core data?
  3. What is the difference between c++ new and malloc?
  4. Can c++ inherit more?
  5. C++ reference and pointer difference?
  6. How to determine if two linked lists have an intersection?
  7. What is the difference between heap and stack? Why do they do that?
  8. Add a Max function interface to the stack that returns the maximum value of the current stack.
  9. Given a sorted array of integers array[] and the integer n, how can we find two numbers that sum to n?
  10. What if it’s not sorted?
  11. A string, how to find the first character that occurs only once?

Second interview

  1. Inverted string
  2. Check whether the integer is $2^n$
  3. How to find the shortest path from the top left corner to the bottom right corner of an m* N checkerboard with some squares that cannot be moved?
  4. What happens when iOS hits the Home button?
  5. What about memory allocation in c++?
  6. What are the common containers in c++?
  7. What’s the difference between queue and vector?
  8. What is the underlying implementation of vector?
  9. TCP three-way handshake? Why not twice?
  10. Is there a server push mechanism in the project?

conclusion

There are not many resumes for autumn recruitment, and there are only a few interviews. There are still a few interviews to be arranged, and then there will be updates and updates. If you want to see the answers, or feel that the format is not very clear here, I have also summarized most of the answers on Github