Thử thách lập trình về Competitive-programming

Luyện Competitive-programming với 10 thử thách lập trình từ dễ đến khó. Mỗi thử thách chạy ngay trên trình duyệt, có kiểm thử tức thì, AI nhận xét code và lời giải cộng đồng để so sánh.

Trung bình · 1 Khó · 9

Kỹ năng bạn sẽ luyện: Bảng tần suấtChia để trịCửa sổ O(n)Deque đơn điệuHai con trỏMax tiền tốMở rộng và thu hẹp cửa sổNgăn xếp đơn điệuNgười du lịchO(log n)Phân hoạchQHĐ bitmask
  • Python · C++ · C#
  • Kiểm tra tự động
  • Đánh giá mã bằng AI
  • Giải pháp cộng đồng
226
Thử thách
2
Giải pháp đã chia sẻ
3
Ngôn ngữ

Tất cả thử thách

Tìm theo chủ đề, ngôn ngữ hoặc độ khó.

10 thử thách
Khó

Shortest Delivery Tour

Visit every city once and return home as cheaply as possible.

Bạn sẽ học QHĐ bitmaskNgười du lịch
AdvancedBitmasksCompetitive-programmingDynamic-programming
Chưa có lời giải
Khó

Minimum Window Substring

Find the shortest piece of text containing all required characters.

Bạn sẽ học Mở rộng và thu hẹp cửa sổBảng tần suất
AdvancedCompetitive-programmingSliding-windowStrings
Chưa có lời giải
Khó

Strongly Connected Components

Count groups of nodes that can all reach each other.

Bạn sẽ học Thuật toán đồ thịTarjan hoặc Kosaraju
AdvancedCompetitive-programmingGraphs
Chưa có lời giải
Khó

Median of Two Sorted Arrays

Find the median of two sorted lists combined.

Bạn sẽ học Tìm điểm chiaO(log n)
AdvancedBinary-searchCompetitive-programming
Chưa có lời giải
Trung bình

K-th Smallest Element

Find the k-th smallest value without fully sorting.

Bạn sẽ học QuickselectPhân hoạch
AdvancedCompetitive-programmingSorting
Chưa có lời giải
Khó

Largest Rectangle in a Histogram

Find the largest rectangle that fits under a histogram.

Bạn sẽ học Ngăn xếp đơn điệuTính diện tích
AdvancedCompetitive-programmingStacks
Chưa có lời giải
Khó

Count Inversions

Count the out-of-order pairs in a list.

Bạn sẽ học Sắp xếp trộnChia để trị
AdvancedCompetitive-programmingSorting
Chưa có lời giải
Khó

Trapping Rain Water

Compute how much rain water an elevation map holds.

Bạn sẽ học Hai con trỏMax tiền tố
AdvancedArraysCompetitive-programmingGreedy
Chưa có lời giải
Khó

Sliding Window Maximum

Report the maximum of every window of k numbers.

Bạn sẽ học Deque đơn điệuCửa sổ O(n)
AdvancedCompetitive-programmingSliding-window
Chưa có lời giải
Khó

Matrix Chain Multiplication

Find the cheapest order to multiply a chain of matrices.

Bạn sẽ học QHĐ trên đoạnTối ưu hóa
AdvancedCompetitive-programmingDynamic-programming
Chưa có lời giải