Article Directory
operating system
1. Process and Thread
- A process can have multiple threads, and threads depend on the existence of the process
- The process has an independent memory unit, and multiple threads share the memory unit (code segment, data segment, extended segment (heap)) of the process, and the thread is unique: the stack segment.
- The process is the smallest unit of resource allocation, and the thread is the smallest unit of CPU scheduling.
- System overhead: The process switching overhead is much greater than the thread switching overhead. (When a process is created or cancelled, the system must allocate or reclaim resources, such as memory space, I/O devices, etc., threads only need to save and set the contents of a few registers.)'
- Thread communication is easy, and inter-process communication requires synchronization and mutual exclusion.
2. Inter-process communication method:
- pipeline
- System IPC (message queue, semaphore, shared memory)
- Socket socket
3. Communication between threads
- Critical section
- Mutex
- signal
- Event (signal)
computer network
1. HTTP header structure
Request message:
Response message
2. The difference between HTTP HTTPS
3. HTTP status code
1xx: Prompt message
2xx: Success
3xx: Redirect
4xx: Client error
5xx: Server error
4. The difference between GET and POST
get: request resource
post: submit resource
Algorithm question
- Symmetric Binary Tree
- Spiral matrix
- Use rand()% 5 to generate the function of rand()% 7.
- A string of length N deletes K characters, making the lexicographical maximum (monotonic stack)
- Linked list sorting (merge sort, there is also a non-recursive unanswered up).
Reference
2021 Autumn Recruitment Faced by
Niuke.com Operating System Knowledge
Knowing Interview Sharing (Faced by)
Meituan Backstage Development (one side)