โจทย์ เขียนโปรแกรม

ฝึกทักษะการแก้ปัญหาด้วยโจทย์กลางที่รองรับ Python, C++ และ C# ทุกคำตอบจะถูกตรวจสอบอัตโนมัติและรีวิวโดย AI

  • Python · C++ · C#
  • ทดสอบอัตโนมัติ
  • รีวิวโค้ดโดย AI
  • แนวทางจากชุมชน
เส้นทางการเรียนรู้
150
โจทย์
2
วิธีแก้ที่แชร์
3
ภาษา

โจทย์ทั้งหมด

ค้นหาตามหัวข้อ ภาษา หรือระดับความยาก

150 โจทย์
ง่าย

Distance Between Points

Compute the straight-line distance between two points.

BeginnerFunctionsLearning-pathmath
ยังไม่มีวิธีแก้
ยาก

Word Break

Decide whether text can be split into dictionary words.

AdvancedDynamic-programmingHackathonStrings
ยังไม่มีวิธีแก้
ยาก

ตัดสี่เหลี่ยมผืนผ้าให้เป็นสี่เหลี่ยมจัตุรัส

หาจำนวนครั้งในการตัดตรงที่น้อยที่สุดเพื่อให้ได้แต่สี่เหลี่ยมจัตุรัสเท่านั้น

Dynamic-programmingGeometry
ยังไม่มีวิธีแก้
ปานกลาง

Gradebook Top Student

Find the student with the highest average score.

BeginnerFunctionsGridsLearning-path
ยังไม่มีวิธีแก้
ยาก

Longest Path in a DAG

Find the heaviest path in a task dependency graph.

AdvancedGraphsHackathonTopological-sort
ยังไม่มีวิธีแก้
ง่าย

คะแนนตัวอักษรในคำ

บวกค่าคะแนนของแต่ละตัวอักษรในคำหนึ่งคำ

Lookup-tablesStrings
ยังไม่มีวิธีแก้
ปานกลาง

Shortest Weighted Routes

Find the minimum total route cost from city 1 to each city.

GraphsPriority-queuesShortest-path
ยังไม่มีวิธีแก้
ยาก

Minimum Network Connection Cost

Choose undirected links so that every vertex can reach every other vertex, with minimum total cost.

Disjoint-setsGraphsMinimum-spanning-tree
ยังไม่มีวิธีแก้
ง่าย

Min and Max Together

Find the smallest and largest value in one pass.

ArraysBeginnerFunctionsLearning-path
ยังไม่มีวิธีแก้
ปานกลาง

Count Islands

Count groups of connected land cells in a grid.

BeginnerGridsLearning-pathRecursion
ยังไม่มีวิธีแก้
ง่าย

Every Other Character

Keep the characters at even positions.

BeginnerLearning-pathStrings
ยังไม่มีวิธีแก้
ยาก

Hotel Room Allocation

Assign arriving groups in order.

Segment-treesSimulation
ยังไม่มีวิธีแก้
ปานกลาง

ผลคูณสามเหลี่ยมมุมฉาก

หาผลคูณด้านที่มากที่สุดของสามเหลี่ยมมุมฉากจำนวนเต็มที่มีเส้นรอบรูปที่กำหนด

GeometryNumber-theory
ยังไม่มีวิธีแก้
ง่าย

Triangle Classification

Classify three side lengths as invalid, equilateral, isosceles, or scalene.

ConditionsGeometry
ยังไม่มีวิธีแก้
ง่าย

First Negative Index

Find where the first negative number appears.

ArraysBeginnerLearning-path
ยังไม่มีวิธีแก้
ปานกลาง

Island Perimeter

Measure the coastline of land cells in a grid.

AdvancedGridsHackathon
ยังไม่มีวิธีแก้
ง่าย

Average of Three

Average three whole numbers.

BeginnerLearning-pathVariables
ปานกลาง

List Primes With a Sieve

Find primes up to a limit by marking composite multiples.

Number-theorySieve
ยังไม่มีวิธีแก้