2019 Autumn Recruitment C++ Personal Face Sutra collection (including cvte, bigo, tiger, Netease, Pin Xixi, etc.)

Introduction:

In order of personal interview time, try to restore the interview questions as much as possible.

8.19 Tencent approves client development in advance

  1. Hand tear kmp algorithm
给定一个字符串数组,和一个子串,求字符串中是否存在子串,如果存在则返回首个匹配到的索引位置,否则,返回-1。不能调用库函数。例如:
字符串数组:“Integrity Procative Collaboration Innovation”
子串:”tegri”
返回:2
int IndexOfSubstr(const char* const raw_str, const char* const sub_str)
{
}
  1. The way function passes
  2. The difference between reference and copy
  3. Pros and cons of citation and pros and cons of copy

8.24 Sangfor Youzhao C++ R&D (Internet of Things)

  1. C++ memory partition, where is the uninitialized global variable placed, if it is compiled, will it be located in the binary file?
  2. What is a wild pointer and is there any tool to detect it?
  3. Inter-process communication method, know the mutex lock and what lock (not heard)
  4. For a structure, can memcpy be used to judge whether the contents of two structures are different?
  5. Do you know a hash table, how to resolve conflicts, if there are only 32 slots, how to store thousands of data.
  6. The difference between routers and Layer 2 switches
  7. Have you used a shell script?
  8. Do you know how to traverse a binary tree?
  9. Implementation of post-order traversal
  10. Assuming that 4 people cross the river, the time for each person to cross the bridge is 1, 2, 5, 8. There is only one flashlight, at most two at a time, how to cross the bridge the fastest
  11. If it is n people how to calculate his crossing time
  12. Why are the functions of the arp protocol used?
  13. The idea of ​​quick sort

8.26 Tiger officially approved the development of windows

  1. The difference between c and c++
  2. Your understanding of polymorphism
  3. Bubbling function
  4. The idea of ​​quick sort
  5. What data structures have been learned
  6. Your impression of mfc
  7. Which ui interfaces have been used
  8. Have you used qt?

8.26 360 software development approved in advance

  1. Hand tear strcpy
  2. How to judge the big end, handwritten code
  3. Talk about tcp congestion control
  4. The difference between lvalue references and rvalue references
  5. The difference and use of four types of cast cast
  6. Talk about smart pointers
  7. What object-oriented programming work has been done
  8. Understand perfect forwarding
  9. Do you understand future and thread?
  10. What are the tcp/ip four-layer model and the osi seven-layer model?
  11. Inter-process message communication method
  12. The difference between process and thread

8.26 Tiger officially approve windows development

  1. Talk about the message mechanism under windows
  2. System set and user set
  3. C++ memory management
  4. Is stl thread safe or unsafe
  5. What to do if there is a memory leak in windows
  6. How to delete the nth node in the linked list
  7. The difference between tcp and udp
  8. How does tcp determine reliable transmission
  9. How to realize the process from the user clicking the mouse to the control response

9.5 Bigo officially batches the client development side

  1. project
  2. Singleton mode thread safe shredded code
  3. Application scenarios and working methods of observer mode
  4. Do you know the responsibility chain design pattern
  5. Flow control and congestion control
  6. TCP, udp application scenarios
  7. Talk about red-black trees
  8. Which sorting algorithms are stable
  9. What are the ways to create threads in c++
  10. Have you used oracle and mysql
  11. What are the ways to join
  12. Talk about left connection and right connection
  13. Have you understood the architecture of mobile development?
  14. What else have you used besides C++, have you used Java?
  15. What do you want to ask me

9.8 AutoNavi Map officially approved the development of C++

  1. Your understanding of object-oriented
  2. What are the principles of inheritance
  3. How virtual functions work
  4. Are the virtual function table and virtual table pointer an object or
  5. Can abstract classes instantiate objects
  6. Public inheritance, private inheritance, the use scenarios of protected inheritance, and your judgment of which principle to use
  7. There is the concept of interface in c#, so what kind of behavior do you think reflects the characteristics of the interface in C++
  8. The difference between rewriting and overloading
  9. Which class functions need to be set as virtual functions, how do you judge that a function needs to be declared as a virtual function
  10. Base class pointer operation base class object, and base class pointer operation derived class object, and derived class pointer operation base class object, and derived class pointer operation derived class object, the performance when operating the function of the same name
  11. What if the function with the same name is a virtual function
  12. C++ virtual memory distribution
const int i=1024
char *str =”"hello"
在全局范围和局部范围声明时在内存的分布情况
int i=1024
static int i=1024
在全局声明使用的区别和局部声明的区别
  1. Have you understood which containers in the stl container, and the scenarios and differences used
  2. The principle and specific implementation of expansion in vector
  3. The underlying implementation and performance difference between map and unordered map, get elements and delete added elements.
  4. Can you talk about which sorting algorithm you know. What algorithm to use in what scene
  5. Do you understand merge sort?
  6. What are the principles of designing database tables and how do you design a table
  7. How to increase the i/o speed of the database
  8. Have you practiced in multi-threading, or what do you know about multi-threading
  9. Have you understood the paradigm?
  10. Where do you want to go in the future
  11. Do you understand big data and image processing?
  12. Have you ever understood the traversal method of a binary tree, what traversal methods are there in a binary tree, what traversal sequence is, and how is non-recursion achieved?
  13. What are your hobbies
  14. What c++ books have you read
  15. How is your english
  16. Is there any inconvenience in working place in Beijing?

Rhetorical question

  1. Do you think that the foundation is important or the application is important
    for fresh graduates. The foundation is more important. The interviewer pays more attention to your potential. Application is the second consideration. Practical experience is the best, but not every school has the opportunity to practice. So the foundation is more important

  2. What are your opinions on the study of fresh graduates?
    If you choose a professional field, you should learn the knowledge of the corresponding field and do the practice in the corresponding field. The implementation of knowledge is very important.

9.9 cvte officially approved the development of c++ software

  1. Three characteristics of c++
  2. What is polymorphism
  3. How virtual functions work
  4. Is there only one virtual table pointer if it is multiple inheritance?
  5. Have you used class templates?
  6. The difference between function template and class template
  7. Have you used stl and which ones
  8. An expansion principle of vector
  9. How would you design if you allow you to dynamically delete the vector and then reduce the capacity?
  10. Have you understood type extraction?
  11. Know the features of c++11
  12. What are the ways to create threads in c++
  13. Have you learned about smart pointers?
  14. How smart pointers solve memory leaks
  15. How does weak ptr solve the problem of circular references
  16. The principle of tcp sliding window
  17. The difference between tcp and udp
  18. Why tcp cannot be understood twice
  19. Why can't wave four times be three times
  20. How to solve the problem of tcp sticky packets
  21. Hand tearing algorithm: how to judge whether a linked list has a ring

9.9 cvte officially approves the two sides of c++ software development

  1. How to solve the tcp sticky package problem (I didn't answer it well and asked again)
  2. How does tcp ensure reliable transmission
  3. What is the stop-wait protocol of tcp
  4. Thread synchronization
  5. How to pass signals between threads
  6. c++ how to transmit signals
  7. What is a memory leak
  8. If I new a memory, then the process is killed by the system before delete. Is this a memory leak?
  9. What permissions does linux 755 refer to?
  10. Wine is to enable windows programs to be used under linux, how do you think he solves it
  11. The difference between system call and function call
  12. dll file
  13. The difference between static library and dynamic library
  14. Under what circumstances will dll missing occur
  15. How to solve the problem of memory leaks
  16. How do you think these tools for locating open source memory leaks are implemented?
  17. What is the suffix of executable files under c++ and executable files under linux
  18. What are the file suffixes of c++ under windows and why are they used?
  19. How to debug if there is an error that needs to be looped many times during the debugging process
  20. What problems have you encountered in programming recently
  21. Hand tear singleton mode thread safe writing
  22. If multiple threads determine that the current object has not been created at the same time, what should be done
  23. What features can be used in c++11 to replace the static writing in the singleton mode
  24. The difference between git and svn
  25. The difference between git and github
  26. Talk about the map in stl
  27. The difference between map and unordered map

9.10 Pinduoduo officially approves server engineers

Asked me two algorithm questions throughout the whole process, let me rationalize my thinking and let me write

  1. The first question is one of the written test questions, I don’t remember very clearly
给定一个字符串,其中包含 数字(0-9)、字母(a-z,A-Z)、小数点(.),要求从中找出子串,该子串需满足
1. 是一个合法的 十进制 数字,如是一个整数、浮点数
2. 是符合1的条件里的所有子串里长度最长的,小数点也算在长度里,但是不影响大小的前导或者末尾0不算在长度里,如123.45的长度是6,00123的长度是3,123.4500的长度是6,123.046的长度是7

如果同时符合1和2的子串有多个,按数值大小从大到小全部输出

输入 123.456abc789.678.23500
输出 789.678 678.23500 123.456

9.11 Bigo officially batches two aspects of client development

  1. The difference between tcp and udp
  2. How to implement tcp based on udp
  3. Ideas for constructing Huffman numbers
  4. When to use the stack and when to use the queue
  5. What is the memory leak
  6. The difference between null pointer and wild pointer
  7. Under what circumstances a wild pointer
  8. Under what circumstances will stack exception occur
  9. Hand tearing algorithm: Determine whether an integer is a palindrome. Use different methods to consider time complexity and space complexity. Write an algorithm that uses the least auxiliary space
  10. What projects have you done
  11. How to estimate the proportion of a piece of greenery in the current area

9.11 Bigo officially batches three aspects of client development-hand tearing algorithm

  1. Complete the column traversal of the binary tree, and the nodes in the same column are output in the order from the root to the left
  2. Given a gold coin, you are required to find the smallest number of combined coins.
  3. Top(k) problem, how to find the k-th largest number. The execution process of the small root heap. Drawing

9.16 NetEase officially approved the client development side

  1. C++ three characteristics
  2. Inheritance, encapsulation, polymorphism
  3. public, protect, private talk about
  4. The difference between shared inheritance, protected inheritance, and private inheritance.
  5. Since private inheritance, derived classes can not be accessed, why inheritance
  6. How to access private members of other classes
  7. Since private members just don’t want to be accessed by the outside world, why do you design a friend method to be able to access private members?
  8. The difference between function overloading and function template
  9. How to call the function template to the corresponding overloaded version
  10. Does the function template store all overloaded versions in the binary file, or what?
  11. Function overload max. Is it a direct comparison?
  12. The class object passed by the function overload max, how to achieve it through direct comparison
  13. Overload operator<What are the points to be aware of
  14. Who maintains the virtual function table
  15. What is stored in the virtual function table
  16. The base class has a virtual function fun, and the derived class has a virtual function fun. Use the base class pointer to point to which function is called for the derived class object
  17. The specific structure of the derived virtual function table
  18. How does the base pointer dynamically know the dynamic object it points to?
  19. Talk about abstract classes
  20. Can abstract classes have member variables
  21. Scene question: the number of 0-10000. There are already 500 numbers, which can be repeated to determine whether a certain number exists. How to design
  22. Do you understand the message mechanism under windows?
  23. How to ensure the security of the database for multiple additions, deletions and modifications
  24. Do you understand the affairs?
  25. How TCP achieves reliable transmission
  26. The difference between c struct and c++ struct
  27. Do you usually have experience in packaging?
  28. Do you think algorithmic questions are helpful in your own work besides dealing with the company's written examination?

9.16 AutoNavi Map officially approved the two sides of C++ R&D

  1. The role of const, what is the difference between the front of the function and the back of the function
  2. The difference between struct and class, when to use struct and when to use class
  3. struct byte alignment, what are the benefits of byte alignment
  4. c++ memory management
  5. Reverse binary tree, recursive and non-recursive practices
  6. Time complexity of bubble sort and quick sort
  7. The way to find all reachable paths from site a to site b, consider the query
  8. Have you understood the A* algorithm?
  9. Implementation of type extraction
  10. Didn't plan to enter postgraduate?

9.18 Pinduoduo officially approved the second side of the server engineer

  1. Crazy project
  2. Have you understood the A* pathfinding algorithm?
  3. The difference between multithreading and multiprocessing, when to use multithreading and when to use multiprocess
  4. The initialization sequence of a class object data
  5. The difference between tcp and udp
  6. When to use tcp and when to use udp
  7. Why are three tcp handshake three times?
  8. Why retransmit and under what circumstances
  9. Sliding window understand
  10. Calculate the number of paths for a horse from the lower left corner to the lower right corner (chess horse).
  11. If it is not specified from the lower left corner to the lower right corner. Specify from a to b. How do you determine its direction
  12. Add a data to the red-black tree, how does it achieve balance
  13. The way to traverse the binary tree. When to use pre, post, middle, and level
  14. How to judge whether a linked list has a ring
  15. How many steps do you need to take in a fast and slow pointer

9.19 Tiger officially approved three aspects of windows development

There may be a cutscene from three sides, and basically did not ask any questions, just asked a reverse Polish and smart pointer and an algorithm question

Pass on the experience, build up character, and hope you all get your favorite offer

Insert picture description here

Guess you like

Origin blog.csdn.net/weixin_39139505/article/details/102471681