If you're seeing this message, it means we're having trouble loading external resources on our website.

Хэрэв та вэб шүүлтүүртэй газар байгаа бол домэйн нэрийг *.kastatic.org and *.kasandbox.org блоклосон эсэхийг нягтална уу.

Үндсэн товъёог

# Unit: Алгоритм

## Алгоритм хичээлийн удиртгал

Алгоритм гэдэг нь тодорхой нэг төлвөөс зорилгодоо хүрэх хүртлэх арга зам, алхмуудын дараалал юм. Бид өдөр тутмын амьдралдаа байнга л алгоритм зохиож түүнийгээ хэрэгжүүлж байдаг. Энэ бүлэг хичээлээр алгоритмын тухай дэлгэрэнгүй үзээрэй.

## Binary search

Learn about binary search, a way to efficiently search an array of items by halving the search space each time.

## Asymptotic notation

Learn how to use asymptotic analysis to describe the efficiency of an algorithm, and how to use asymptotic notation (Big O, Big-Theta, and Big-Omega) to more precisely describe the efficiency.

## Selection sort

Learn selection sort, a simple algorithm for sorting an array of values, and see why it isn't the most efficient algorithm.

## Insertion sort

Learn insertion sort, another simple but not very efficient way to sort an array of values.

## Recursive algorithms

Learn the concept of recursion, a technique that is often used in algorithms. See how to use recursion to calculate factorial and powers of a number, plus to generate art.

## Ханой хотын цамхагууд

Use the recursive technique to solve the Towers of Hanoi, a classic mathematical puzzle and one reportedly faced by monks in a temple.

## Merge sort

Learn merge sort, a more efficient sorting algorithm that relies heavily on the power of recursion to repeatedly sort and merge sub-arrays.

## Quick sort

Learn quick sort, another efficient sorting algorithm that uses recursion to more quickly sort an array of values.

## Graph representation

Learn how to describe graphs, with their edges, vertices, and weights, and see different ways to store graph data, with edge lists, adjacency matrices, and adjacency lists.