Available question text
Given a full 6-digit hex color like "#ABCDEF", find the closest "shorthand" color of the form "#XYZ" (which expands to "#XXYYZZ") by minimizing RGB distance; the optimal solution picks for each 2-digit channel the nearest repeated hex digit value (0x00,0x11, …, 0xFF) independently.
Related questions
Continue with questions that share topics or the same question type.
- Cheapest Daily Shirt Colors With No Color Repeated on Consecutive Days
Coding · Dynamic Programming
- Check if Two Chessboard Squares Have the Same Color
Coding
- Color the Triangle Red
Coding
- Count Pairs Of Similar Strings
Coding
Sources · 1 reference
These records explain where the question appears. A company tag or candidate report does not guarantee a future interview question.
Hello Interview · 1 record
No company association
Leetcode 800. Similar RGB Color
Reported date not specified · 0 source reports
Source snapshot: Nov 12, 2026
View source