What Lenovo Backend Interview Reveals: Salary Insights, Deadlock Basics, DNS, TLS Handshake, and Java ArrayList Deep Dive

This article shares Lenovo's 2026 graduate hiring salary breakdown, explains deadlock conditions and prevention, outlines DNS resolution steps, details the TLS handshake process, and provides an in‑depth guide to Java's ArrayList implementation, performance, and thread‑safety concerns.

IT Services Circle
IT Services Circle
IT Services Circle
What Lenovo Backend Interview Reveals: Salary Insights, Deadlock Basics, DNS, TLS Handshake, and Java ArrayList Deep Dive

The author, known as 小林, first presents a table of Lenovo 2026 graduate hiring offers, showing total compensation ranging from 15 w to 28 w across roles (software development, AI application development, Android, embedded, test) and locations (Beijing, Tianjin, Wuhan). The data suggests that Lenovo’s salaries are heavily influenced by education level, with master’s graduates generally receiving higher packages than bachelor’s graduates.

After discussing the salary variance, the author shares a personal anecdote about a candidate who received a 32 w offer from Lenovo and a 36 w offer from another internet company, ultimately recommending Lenovo due to its lower work intensity, better benefits, and stronger company reputation.

Lenovo Backend Interview (First Round)

1. What is a deadlock and how does it occur?

Mutual exclusion : multiple threads cannot simultaneously use the same resource.

Hold and wait : a thread holding one resource requests another that is already held.

Non‑preemptive : a held resource cannot be forcibly taken away before the owning thread releases it.

Circular wait : the waiting threads form a cycle of resource requests.

2. How to avoid deadlock?

Break any one of the four conditions; the most common practical method is the resource ordering strategy , which enforces a consistent acquisition order for all threads, thereby eliminating circular wait.

3. Which OSI layer does the IP protocol belong to?

Network layer.

4. Which protocol converts a domain name to an IP address?

DNS protocol.

5. Explain the DNS resolution process.

The client sends a DNS query for www.server.com to its configured local DNS server.

If the local server has a cached record, it returns the IP; otherwise it queries the root DNS server.

The root server points to the .com top‑level domain (TLD) server.

The local server asks the TLD server for the authoritative server of www.server.com.

The TLD server returns the address of the authoritative DNS server.

The local server queries the authoritative server, which finally returns the IP address.

The local server forwards the IP to the client, which can now establish a connection.

6. Have you ever edited the hosts file?

Editing the hosts file binds a domain name directly to an IP address, bypassing DNS. It is useful for testing a website before it is publicly deployed.

7. What is the TLS handshake process?

The traditional RSA‑based TLS handshake consists of four rounds:

ClientHello : the client sends supported TLS version, a random number (ClientRandom), and cipher suites.

ServerHello : the server replies with the selected TLS version, its own random number (ServerRandom), chosen cipher suite, and its digital certificate.

Key exchange : the client extracts the server’s public key from the certificate, encrypts a pre‑master secret, and sends it to the server. Both sides then derive the session key.

Finished : the server sends a Finished message encrypted with the session key, and the client does the same, completing the handshake. Subsequent communication uses the established session key over ordinary HTTP.

8. Common data structures (brief overview)

Array – contiguous memory, O(1) random access, O(n) insertion/deletion.

Linked list – nodes with pointers, O(1) insertion/deletion, O(n) random access.

Stack – LIFO, operations at the top only.

Queue – FIFO, enqueue at tail, dequeue at head.

Tree – hierarchical, suitable for representing file systems, organization charts, etc.

9. What is Java's ArrayList ?

ArrayList

is a dynamic array implementation in the java.util package that implements the List interface. It provides ordered, repeatable storage and automatically expands its internal array when needed.

10. Features of ArrayList

Dynamic expansion : when the element count reaches capacity, the array grows (default new capacity = old capacity × 1.5). You can specify an initial capacity via new ArrayList<>(initialCapacity).

Ordered and allows duplicates , including null values.

Not thread‑safe ; concurrent modifications can cause data loss, array‑index errors, or ConcurrentModificationException. Use Collections.synchronizedList or CopyOnWriteArrayList for thread safety.

Efficient random access : get(int index) runs in O(1).

11. How does ArrayList insert elements?

Two main scenarios:

1. Append at the tail ( add(E e) )
public boolean add(E e) {
    // Ensure capacity for size+1
    ensureCapacityInternal(size + 1);
    // Insert element and update size
    elementData[size++] = e;
    return true;
}

Steps:

Check capacity; if insufficient, trigger grow() to allocate a larger array.

Place the element at elementData[size] and increment size.

2. Insert at a specific index ( add(int index, E element) )
public void add(int index, E element) {
    if (index > size || index < 0) {
        throw new IndexOutOfBoundsException();
    }
    ensureCapacityInternal(size + 1);
    System.arraycopy(elementData, index, elementData, index + 1, size - index);
    elementData[index] = element;
    size++;
}

Steps:

Validate the index.

Ensure capacity (same as tail insertion).

Shift elements from index onward one position to the right using System.arraycopy.

Place the new element at elementData[index] and increment size.

12. Why is ArrayList not thread‑safe?

All mutating methods lack synchronization, so concurrent threads can interleave operations on elementData and size, leading to:

Non‑atomic size++ causing lost updates.

Concurrent writes to the same array slot overwriting each other.

Inconsistent modCount resulting in ConcurrentModificationException.

Visibility issues because size is not volatile.

Examples illustrate element loss when two threads write to the same position and array‑index out‑of‑bounds exceptions when both threads think there is still space.

Original Source

Signed-in readers can open the original source through BestHub's protected redirect.

Sign in to view source
Republication Notice

This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactadmin@besthub.devand we will review it promptly.

JavadeadlockDNSArrayListTLS Handshakesalary analysisbackend interview
IT Services Circle
Written by

IT Services Circle

Delivering cutting-edge internet insights and practical learning resources. We're a passionate and principled IT media platform.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.