Recorded after "Interview @ Taobao"

Source: Internet
Author: User

I personally think that the Taobao interview is more technical than Alibaba, but it is also divided into two sides, but this time it is true that the test is true becauseAlgorithmSome of them are terrible, but they have changed and changed ......

On the one hand: the opening ceremony is also a self-introduction (it seems that this is the same law). After that, I was asked to write a string hash function, mainly for examination.CodeI wrote a hash similar to the bkdrhash function, and explained it to him. Then I didn't seem to talk about any other technology, mainly about the project ......

Aspect 2: disconnected. Unlike Alibaba, all Taobao problems seem to be concentrated on the two sides, which is difficult to solve ......

Question 1: a lca (the most recent public master first problem) is to give you two nodes in the tree and ask them for their recent public master first ......

As we all know after ACM, the typical tajian Algorithm for offline processing can be considered when the number of queries is large, but the number of queries is too small, you can go up from these two nodes in sequence (the most water method )......

Question 2: Let me implement map in C ++ STL ......

In fact, the internal implementation of this is the cloud like the red/black tree (which is hard to remember), so I pulled the key to build a BST, because it is degraded, you can consider balancing tree and other balancing techniques ...... In short, I feel that my answer is not profound enough ......

Question 3: There are two classes:

View code

 1   Class  A
2 {
3 Int Fa;
4 A ()
5 {
6
7 }
8 };
9
10   Class B:
11 {
12 Int Ibb;
13 B ()
14 {
15
16 }
17 };

Now we use B to define a variable B. In this process, we will ask about the exact sequence in four steps: Allocating space A, calling constructor A, allocating space B, and calling constructor B ...... Everyone knows this ......

Question 4: What modules should an IR system contain ......

This question is mainly related to my project. I guess she just asked me (PS: We just tested IR ...... In short, it must be UI, query processing, text processing, indexing, search, and result sorting ......

Question 5: How are the two definitions different?

View code

1 CharCh;
2  Char *P=(Char *) Malloc (1);

First, from the compiler's point of view, the reference to the first variable ch is to directly reference its content, but for the variable P, because it is a pointer type, it is to take its content as the address and then go to the content, an extra level ......

In addition, considering the storage space, if they are all in the local function, CH and P are certainly in the stack, but P points to the space in the heap ......

It's almost all about these problems. Others are useless. What network does it usually use? Is there a classmate in the class for an interview ......

Then we will have it. Wait for the notification ...... Hope there is no tragedy ......

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.