How to get Ali offer? Alibaba's interview process and interview questions analysis to see how much you can answer correctly? [Interview questions for Ali, Tmall, Ant]

Being able to work in Alibaba is the goal and dream of many developers. In order to help developers improve their interview skills and efficiently clear the interviews of first-line Internet companies, the interview questions are refined and summarized, and they are given to everyone at once.

See how much you can answer correctly. If you can answer 70% of the questions, go to Alibaba and various Internet companies to try your skills.

This article is recommended for everyone to collect and reserve~

This article is shared with friends who need to interview and brush up questions, and I wish you all the best to get the offer you want. This information mainly includes Java basics, data structures, jvm, multithreading, etc. Due to limited space, only a small part is shown below. For interview questions, friends who need the full version can click a link to jump to receive: link: just click! ! ! Password: CSDN
Insert picture description here

[Interview questions for Ali, Tmall, Ant]

Covers: open source, Java collection, JVM, NIO, Dubbo, spike system, high concurrency, distributed, lock, redis, MySQL, Linux, hashMap, middleware, etc.

1. Self-introduction and work experience.

2. What are the advantages of technology.

3. Which middleware have been used.

4. Have not done a workflow engine.

5. The underlying implementation of NIO.

6. JVM basics (must ask), JVM GC principle, how to reclaim memory by JVM.

7. What is the principle of thread pool?

8. The lock mechanism is upgraded.

9. Dubbo principle and related issues such as serialization.

10. How does Dubbo make multiple calls concurrently with one link.

11. Tell me about your understanding of distributed transaction consistency.

12. From a system perspective, which latitude should be considered for distributed.

13. The realization principle of WeChat red envelope.

14. How to realize massive data analysis.

15. What is the difference between API interface (for others to use) and SDI interface.

16. How to implement Hadoop bottom layer (Tmall)

17.threadLocal, thread pool, hashMap/hashTable/coccurentHashMap, etc. (Tmall)

18. Talk about how to design a spike system.

19. Related knowledge points such as virtual machine and IO.

20. Linux commands.

21. An integer array, given a number, find the sum of two numbers in the array equal to this number, and print it out. The time complexity I wrote is high and requires O(n).

22.n integers, find the maximum sum of m consecutive numbers.

23. How much do you know about open source technology.

24.1000 threads are running at the same time, how to prevent not stuck.

25. Parallel concurrent consumption problem.

26. How to deal with hotspots, data, etc. under a large number of high concurrency situations.

27. How to get a port available on a local server.

28. Issues related to flow control.

29. What is the database TPS?

30. The principle of database lock hidden.

31. Distributed lock, Redis cache, Spring aop, system architecture diagram, MySQL features.

32. What are the solutions to cache breakdown?

33. How does Java mine the relevant principles of the collector.

34. What are the Java collections, and what are their characteristics.

35. High-concurrency scenarios related topics: Paying 100,000 people at the same time, how would you design a concurrency plan to ensure that all is sent within 1 minute, for example, a similar scenario will be proposed.

[Alibaba interview questions]

Covers: consistent hashing algorithm, CAP, session, thread pool, reflection mechanism, http protocol, Java virtual machine, distributed system, TCP/IP, OSI, stack, heap, distributed system design, etc.

1. What are the three parts of the Java event mechanism? Introduce them separately.

2. The reason for using thread pool?

3. What are the functions of the thread pool?

4. What are the several common thread pools and their respective usage scenarios?

5. What kinds of work queues are there in thread pools?

6. How to understand unbounded queue and bounded queue?

7. Several important parameters and process descriptions in the thread pool.

8. What is the reflection mechanism?

9. Talk about the role of reflection mechanism.

10. Will the reflection mechanism have performance problems?

11. How do you understand the http protocol?

12. Talk about the workflow of the http protocol.

13. What are the request submission methods for http?

14. What status does the 200,302,403,404,500,503 in http represent?

15. What is the difference between http get and post?

16. How do you understand cookie and session, and what are the differences?

17. What is web caching? What are the advantages?

18. What is https and how does https work?

19. What is an http proxy server and what is it for?

20. What is virtual host and its implementation principle?

21. What is the Java virtual machine and why should I use it?

22. Talk about the life cycle and architecture of the Java virtual machine.

23. Talk about the Java memory area.

24. What is a distributed system?

25. What aspects would you consider for distributed systems?

26. Why is the TCP/IP protocol unreliable?

27. Which seven-layer model does OSI have? Which four-layer model is TCP/IP?

28. The three-way handshake of the TCP protocol, the four-way wave process.

29. Why is TCP a three-way handshake for establishing a connection, but a four-way handshake for closing a connection? Why can't I connect with two handshake?

30. Why does the TCP TIME_WAIT state need to wait for 2MSL before returning to the CLOSED state?

31. What are DoS, DDoS, DRDoS attacks? How to defend?

32. Describe the Java exception hierarchy.

33. What is inspection exception, not subject to inspection exception, runtime exception? And give examples to illustrate.

34. Will the finally block be executed?

35. Under normal circumstances, when a return statement is encountered in a try block or a catch block, will the finally statement block be executed before or after the method returns?

36. The execution order of try, catch, and finally statement blocks.

37. In the Java virtual machine, how many types of data can be divided into?

38. How to understand stack and heap? What's in the heap? What is stored in the stack?

39. Why distinguish between heap and stack? Isn't it possible to store data in the stack?

40. In Java, what is the starting point of the stack, which is also the starting point of the program?

41. Why not put the basic types in the pile?

42. What about passing values ​​when passing parameters in Java? Or pass by reference?

43. Is there a concept of pointer in Java?

44. In Java, what parameters are used to set the stack size?

45. How much space does an empty Object object occupy?

46. ​​What are the types of object reference types?

47. Talk about garbage collection algorithm.

48. How to solve the problem of memory fragmentation?

49. How to solve the problem of object creation and object recycling that exist at the same time?

50. Talk about memory generation and life cycle.

51. Under what circumstances trigger garbage collection?

52. How to choose a suitable garbage collection algorithm?

53. What three types of garbage collectors does JVM have?

54. Is there a limit to the maximum heap size in JVM?

55. How to tune the JVM? What are the methods?

56. What parameters are used to set the heap size?

57. Which garbage collector is preferred for throughput? Is response time a priority?

58. How to understand the memory leak problem? What conditions can cause memory leaks? How to solve?

59. From the perspective of distributed system deployment, what are the layers?

60. How to solve the problem of data access in the business layer?

61. In order to solve the burden of the database server, how to do the distribution of the database?

62. What is the famous Byzantine generals problem?

63. Talk about the concept of CAP.

64. How to understand strong consistency, monotonic consistency and ultimate consistency?

65. What strategies would you consider when designing distributed systems?

66. What is the most common data distribution method?

67. Talk about the consistent hash algorithm.

68. What is paxos?

69. What is the Lease mechanism?

70. How to understand the main selection algorithm?

[Alibaba interview questions with answers]

1. What are the three major engines of mysql?

The commonly used engines of mysql are InnoDB, MyISAM, Memory, and the default is InnoDB

InnoDB: Disk tables, support transactions, support row-level locks, B+Tree index

ps: Advantages: Has good ACID characteristics. It is suitable for tables with high concurrency and more update operations. Need to use transaction table. Tables that require automatic disaster recovery.

Disadvantages: The reading and writing efficiency is relatively poor compared to MYISAM. The disk space occupied is relatively large.

4 major features of mysql + 4 isolation levels:

MyISAM: Disk table, does not support transactions, supports table-level locks, B+Tree index

ps: Advantages: small footprint and fast processing speed (relative to InnoDB)

Disadvantages: does not support transaction integrity and concurrency

MEMORY (Heap): memory table, does not support transactions, table-level locks, Hash index, does not support Blob, Text large types

ps: Advantages: fast speed, temporary data

Disadvantages: After the loss, when there is no or little negative impact on the project as a whole.

2. What is the hash algorithm of redis used?

Redis should use a consistent hash algorithm-MurmurHash3 algorithm, which has the advantage of low collision rate. Google's improved version of cityhash is also the hash algorithm used in redis.

The existing mainstream big data systems all use MurmurHash itself or improve.

3. Why is nosql faster than sql?

Nosql is a non-relational database, because it does not need to meet the complex characteristics of relational database data consistency, so it is fast;

SQL is a relational database with powerful functions, but there are bottlenecks in efficiency.

4. What is an index and why nosql has no index? nosql has index drops

Indexes are divided into clustered indexes and non-clustered indexes. Clustered indexes are ordered according to the physical location of data storage, while non-clustered indexes are different; clustered indexes can improve the speed of multi-row retrieval, and Non-clustered index is very fast for single row retrieval.

Clustered index: when there is a primary key, a clustered index is created based on the primary key; when there is no primary key, a unique and non-empty index column will be used as the primary key to become the clustered index of this table; if the above two are not satisfied, then Innodb creates a virtual clustered index by itself

Non-clustered indexes: Non-clustered indexes are auxiliary indexes, such as composite indexes, prefix indexes, and unique indexes.

5. What is the difference between B+ tree and B tree?

The non-leaf node of the B-tree stores the pointer of the actual record, and the leaf node of the B+ tree stores the pointer of the actual record

The leaf nodes of the B+ tree are connected by pointers, which are suitable for scanning interval and sequential search.

[Summary of Alibaba Interview Experience]

In summary, the interview questions of the subsidiaries of Alibaba Group mainly focus on:

1. Advanced Java, such as virtual machine, concurrent thread, distributed, NIO, etc.

2. In terms of middleware, such as the realization principle of Redis, clustering, data storage, persistence, etc.

3. The back-end part, such as the mastery of the candidate's MySQL database, from the performance optimization aspects of index, sql slow query, and long transaction.

4. The projects that you have worked on are the focus of the interview, from design to coding, and subsequent environment deployment.

5. Big data-related algorithm questions must be asked.

6. Second-kill and high-concurrency projects are also necessary, mainly to test the candidate's mastery of the technical knowledge points of high-concurrency scenarios.

7. Self-confidence is very important in the interview process. Even if you encounter questions you don't know, you can answer frankly. Asking the interviewer humbly at the end of the interview can give the interviewer the impression of humility and love to learn.

The above is the latest 118 interview questions developed by the Alibaba Department of Advanced Java. The interview questions cover a wide range, from technical foundation to project experience, from technical breadth to technical depth, and to fully explore the skill level of candidates. It is recommended that you spend more time reviewing the past and learning about the new before participating in an interview with any company, so that you will be more calm during the interview process and increase the probability of getting an offer.

Guess you like

Origin blog.csdn.net/a3961401/article/details/108784153