NiuNiu MaTe
Author

NiuNiu MaTe

Joined Tencent (nicknamed "Goose Factory") through campus recruitment at a second‑tier university. Career path: Tencent → foreign firm → ByteDance → Tencent. Started as an interviewer at the foreign firm and hopes to help others.

97
Articles
0
Likes
79
Views
0
Comments
Recent Articles

Latest from NiuNiu MaTe

97 recent articles
NiuNiu MaTe
NiuNiu MaTe
Nov 17, 2021 · Databases

Mastering MySQL Disaster Recovery: Replication Modes and Strategies

This article explains MySQL disaster‑recovery techniques, covering cold and hot backups, same‑city versus remote setups, master‑slave topologies, async, semi‑sync and full‑sync replication, the MAR strong‑sync approach, and practical recommendations for building resilient two‑city three‑center architectures.

MySQLdatabasedisaster recovery
0 likes · 10 min read
Mastering MySQL Disaster Recovery: Replication Modes and Strategies
NiuNiu MaTe
NiuNiu MaTe
Oct 27, 2021 · Fundamentals

Master the House Robber Problem with Dynamic Programming

This article explains the classic House Robber interview question, detailing the problem constraints, illustrating why a naive alternating‑house approach fails, and presenting a clear dynamic‑programming solution with recurrence, base cases, and a concise code example.

DPalgorithmdynamic programming
0 likes · 5 min read
Master the House Robber Problem with Dynamic Programming
NiuNiu MaTe
NiuNiu MaTe
Oct 21, 2021 · Databases

Master MySQL ACID, Isolation Levels, Locks & Indexes – A Deep Dive

This article walks through MySQL's core concepts—including ACID guarantees, the four isolation levels, undo and redo logs, buffer pool flushing, lock types, gap locks, deadlock scenarios, and the B+‑tree based index architecture—providing interview‑ready insights and practical examples.

ACIDB+TreeDatabase Interview
0 likes · 12 min read
Master MySQL ACID, Isolation Levels, Locks & Indexes – A Deep Dive
NiuNiu MaTe
NiuNiu MaTe
Oct 12, 2021 · Fundamentals

How Many Peaches Did the Monkeys Start With? A Math & Code Puzzle

This article presents a classic monkey‑and‑peach puzzle, derives the minimal initial peach count using mathematical reasoning, and then demonstrates a brute‑force Python program that searches for the solution, illustrating how loops and modular checks solve the problem.

Math PuzzlePythonalgorithm
0 likes · 7 min read
How Many Peaches Did the Monkeys Start With? A Math & Code Puzzle
NiuNiu MaTe
NiuNiu MaTe
Oct 7, 2021 · Backend Development

Mastering Zookeeper: Core Concepts, Architecture, and Leader Election Explained

This article provides a comprehensive overview of Zookeeper, covering its purpose as a distributed coordination service, data structures, system architecture, ZAB protocol, leader election mechanisms, watcher functionality, key features, request ordering, synchronization methods, and potential consistency issues.

Distributed CoordinationWatcherZAB Protocol
0 likes · 19 min read
Mastering Zookeeper: Core Concepts, Architecture, and Leader Election Explained
NiuNiu MaTe
NiuNiu MaTe
Oct 4, 2021 · Fundamentals

Master the Basics: 19 Essential TCP/IP and HTTP Interview Questions Explained

This comprehensive guide answers 19 core networking interview questions, covering the TCP/IP five‑layer model, HTTP fundamentals, GET vs POST, ping, status codes, differences among HTTP/1.0, 1.1, 2, 3, HTTPS, TCP connection handshake and teardown, sliding windows, flow control, half‑ and full‑connection queues, packet framing, and the browser request lifecycle.

HTTPHTTP2HTTPS
0 likes · 23 min read
Master the Basics: 19 Essential TCP/IP and HTTP Interview Questions Explained
NiuNiu MaTe
NiuNiu MaTe
Sep 28, 2021 · Backend Development

Master Go Unit Testing: From Basics to Mocking with GoConvey

This article explains what unit testing is, shows how to write Go unit tests using the testing package, demonstrates more expressive assertions with GoConvey, and introduces mock creation with mockery, providing practical code examples and best‑practice tips for backend developers.

GoGoConveymocking
0 likes · 7 min read
Master Go Unit Testing: From Basics to Mocking with GoConvey
NiuNiu MaTe
NiuNiu MaTe
Sep 23, 2021 · Databases

Essential MySQL Interview Guide: Core Concepts, Queries, and Best Practices

This article walks through essential MySQL interview topics, covering basic concepts, OLTP vs OLAP, normalization forms, DML/DDL/DCL, varchar vs char trade‑offs, storage engines, ACID properties, primary and foreign keys, and how to monitor running queries, all presented from an interviewer's perspective.

ACIDDatabase InterviewMySQL
0 likes · 8 min read
Essential MySQL Interview Guide: Core Concepts, Queries, and Best Practices
NiuNiu MaTe
NiuNiu MaTe
Sep 15, 2021 · Fundamentals

How to Maximize Mooncake Profit: Brute Force, Greedy, and DP Solutions

This article presents a classic stock‑like profit maximization problem using mooncake prices, explains the input and expected output, and walks through three solution strategies—brute‑force enumeration, a greedy linear scan, and a dynamic‑programming approach—complete with Go code examples and visual illustrations.

algorithmbrute forcedynamic programming
0 likes · 6 min read
How to Maximize Mooncake Profit: Brute Force, Greedy, and DP Solutions
NiuNiu MaTe
NiuNiu MaTe
Sep 8, 2021 · Backend Development

Mastering Distributed Locks with Redis: From Basics to RedLock

This article explains what distributed locks are, outlines their essential properties, walks through step‑by‑step Redis implementations—from simple SETNX to Lua‑based atomic operations—and discusses reliability strategies such as master‑slave failover and RedLock while highlighting the inherent limits of any distributed lock.

Distributed LockLua scriptingRedis
0 likes · 11 min read
Mastering Distributed Locks with Redis: From Basics to RedLock