Tag

DataStructure

1 views collected around this technical thread.

Architect's Guide
Architect's Guide
May 27, 2025 · Backend Development

Understanding CopyOnWrite (COW) Concept and Its Implementation in Java

The article explains the CopyOnWrite (COW) concept, its read‑write separation benefits for thread‑safe, read‑heavy scenarios, key implementation details in Java’s CopyOnWriteArrayList—including volatile and transient usage—and discusses its memory overhead and eventual‑consistency drawbacks.

ConcurrencyCopyOnWriteDataStructure
0 likes · 5 min read
Understanding CopyOnWrite (COW) Concept and Its Implementation in Java
Java Tech Enthusiast
Java Tech Enthusiast
May 15, 2025 · Fundamentals

Detect Squares Problem – Algorithm Design, Hash‑Map Solutions, and Complexity Analysis

The article first highlights Tencent's Q1 2025 financial results and user metrics, then introduces the LeetCode 2013 'Detect Squares' problem, describing its requirements, example, and offering Java, C++, Python, and array‑based solutions along with time and space complexity analysis.

C++DataStructureDetectSquares
0 likes · 9 min read
Detect Squares Problem – Algorithm Design, Hash‑Map Solutions, and Complexity Analysis
Cognitive Technology Team
Cognitive Technology Team
May 5, 2025 · Fundamentals

Evolution of Java ConcurrentHashMap: From Segment Locks to CAS + synchronized (Java 7 vs Java 8)

This article examines the evolution of Java's ConcurrentHashMap, comparing the segment‑lock implementation in Java 7 with the CAS‑plus‑synchronized, bucket‑level locking and red‑black tree enhancements introduced in Java 8, covering lock mechanisms, data structures, resizing strategies, core operations, performance and suitable use cases.

ConcurrencyConcurrentHashMapDataStructure
0 likes · 11 min read
Evolution of Java ConcurrentHashMap: From Segment Locks to CAS + synchronized (Java 7 vs Java 8)
Code Ape Tech Column
Code Ape Tech Column
Aug 15, 2024 · Backend Development

Comprehensive Guide to TreeUtil: Building, Traversing, Flattening, and Sorting Tree Structures in Java

This article presents a detailed walkthrough of the TreeUtil class, demonstrating how to construct hierarchical tree structures from flat lists, define tree nodes in Java, perform generic and functional implementations of makeTree, traverse trees using pre‑order, level‑order and post‑order methods, flatten trees back to lists, and sort tree nodes recursively, all illustrated with complete code examples.

DataStructureFlattenUtility
0 likes · 16 min read
Comprehensive Guide to TreeUtil: Building, Traversing, Flattening, and Sorting Tree Structures in Java
Rare Earth Juejin Tech Community
Rare Earth Juejin Tech Community
Aug 2, 2024 · Backend Development

Refactoring and Optimizing the WorkQueue Go Library: Design, Implementation, and Performance Evaluation

This article details the author's comprehensive refactor of the WorkQueue Go library, covering the redesign of its sorting heap using a red‑black tree, interface improvements, enhanced data structures, extensive performance benchmarks, and a step‑by‑step usage guide for developers.

DataStructureGoPerformance
0 likes · 43 min read
Refactoring and Optimizing the WorkQueue Go Library: Design, Implementation, and Performance Evaluation
Selected Java Interview Questions
Selected Java Interview Questions
Jul 29, 2024 · Fundamentals

Comprehensive Guide to TreeUtil: Building, Traversing, Flattening, and Sorting Tree Structures in Java

This article introduces a versatile Java TreeUtil class that demonstrates how to construct hierarchical tree structures from flat lists, perform pre-order, level-order, and post-order traversals, flatten trees back to lists, and sort nodes using generic functional interfaces, with detailed code examples.

DataStructureJavaUtility
0 likes · 16 min read
Comprehensive Guide to TreeUtil: Building, Traversing, Flattening, and Sorting Tree Structures in Java
Rare Earth Juejin Tech Community
Rare Earth Juejin Tech Community
Jan 15, 2024 · Backend Development

Understanding Delaying Queue and Priority Queue in WorkQueue: Implementation, Usage, and Underlying Quadruple Heap

This article explains the design, implementation details, and practical usage of the Delaying Queue and Priority Queue modules in the WorkQueue library, covering their inheritance from the core Queue, the role of the Quadruple Heap data structure, and providing Go code examples for integration in backend systems.

DataStructureDelayingQueueGo
0 likes · 16 min read
Understanding Delaying Queue and Priority Queue in WorkQueue: Implementation, Usage, and Underlying Quadruple Heap
Selected Java Interview Questions
Selected Java Interview Questions
Sep 7, 2023 · Backend Development

Understanding Blocking Queues in Java: Concepts, Types, and Core Methods

Blocking queues are thread‑safe data structures in Java that support blocking operations, enabling producer‑consumer coordination; this article explains their definition, differences from List/Set and regular queues, various implementations such as ArrayBlockingQueue and LinkedBlockingQueue, core methods like take and put, and bounded versus unbounded capacities.

BlockingQueueConcurrencyDataStructure
0 likes · 11 min read
Understanding Blocking Queues in Java: Concepts, Types, and Core Methods
DeWu Technology
DeWu Technology
Jul 8, 2022 · Big Data

Optimizing Large-Scale Product Set Refresh with RoaringBitmap

By representing pre‑and post‑refresh SPU sets as RoaringBitmaps and diffing them, the system avoids full‑insert writes, cuts memory usage by orders of magnitude, speeds refreshes by over 50 % and reduces write volume nearly 87 %, solving large‑scale tag‑based product refresh challenges.

BitmapDataStructureHBase
0 likes · 14 min read
Optimizing Large-Scale Product Set Refresh with RoaringBitmap
Java Tech Enthusiast
Java Tech Enthusiast
Aug 29, 2021 · Fundamentals

Java ArrayList: Constructors, add/addAll, set/get, and Iterator Mechanics

Java’s ArrayList offers a no‑arg constructor initializing an empty internal array, lazy default capacity of ten, and overloads for initial capacity or collection copying; its add/addAll methods ensure and grow capacity, set/get access elements, and its iterator tracks modCount to detect concurrent modifications.

ArrayListConcurrencyDataStructure
0 likes · 16 min read
Java ArrayList: Constructors, add/addAll, set/get, and Iterator Mechanics
Top Architect
Top Architect
Jan 7, 2021 · Fundamentals

Android HashMap Source Code Analysis (Based on Android SDK 28)

This article provides a detailed analysis of the Android HashMap implementation in SDK 28, covering its fields, internal Node class, constructors, resizing logic, hash function, collision handling, and related Map implementations, with complete source code excerpts and performance considerations.

CollisionResolutionConcurrencyDataStructure
0 likes · 34 min read
Android HashMap Source Code Analysis (Based on Android SDK 28)
Sohu Tech Products
Sohu Tech Products
Sep 16, 2020 · Fundamentals

Comprehensive Guide to the Java Queue Family – 18 Types, Interfaces, Implementations and Usage

This article provides an in‑depth overview of Java's Queue hierarchy, covering 18 concrete queue classes, their inheritance relationships, core methods, blocking behavior, real‑world analogies, and code examples, making it the most detailed reference on Java queues available today.

BlockingQueueConcurrencyDataStructure
0 likes · 29 min read
Comprehensive Guide to the Java Queue Family – 18 Types, Interfaces, Implementations and Usage
Selected Java Interview Questions
Selected Java Interview Questions
Jul 17, 2020 · Fundamentals

Deep Dive into Java ArrayList: Implementation, Thread Safety, and Common Operations

This article provides an in‑depth explanation of Java's ArrayList, covering its purpose, lack of thread safety, detailed source‑code analysis of fields, constructors and core methods, serialization mechanics, capacity handling, and a simplified hand‑written implementation for interview preparation.

ArrayListCodingInterviewDataStructure
0 likes · 13 min read
Deep Dive into Java ArrayList: Implementation, Thread Safety, and Common Operations
Java Captain
Java Captain
Nov 23, 2019 · Fundamentals

Understanding LinkedHashMap Order and LRU Cache Implementation in Java

LinkedHashMap extends HashMap by maintaining a doubly linked list to preserve insertion or access order, allowing optional LRU cache behavior via the accessOrder flag, and its source code shows how entries are linked, reordered on get, and how to override removeEldestEntry for eviction.

AccessOrderDataStructureHashMap
0 likes · 8 min read
Understanding LinkedHashMap Order and LRU Cache Implementation in Java
Selected Java Interview Questions
Selected Java Interview Questions
Nov 10, 2019 · Fundamentals

Understanding HashMap Collision Resolution and Internal Implementation in Java

This article explains how Java's HashMap stores key‑value pairs, details the hash calculation, index mapping, collision handling via linked lists, the role of load factor, resizing mechanics, and provides annotated source code for core methods such as put, get, and internal Entry class.

DataStructureHashMapHashTable
0 likes · 21 min read
Understanding HashMap Collision Resolution and Internal Implementation in Java
Java Captain
Java Captain
Mar 1, 2019 · Fundamentals

Introduction and Source Code Analysis of Java ArrayList

This article introduces Java's ArrayList as a dynamic array implementation, explains its non‑thread‑safe nature, details its constructors, capacity‑growth strategy, key methods such as ensureCapacity, add, remove, toArray, and examines the underlying source code including array copying utilities.

ArrayListDataStructureJava
0 likes · 13 min read
Introduction and Source Code Analysis of Java ArrayList