Archive | Algorithm

[Algorithm] Optimal Coding – The encryption method Shanon

The content encryption algorithm Shanon Code algorithm In this article I just mentioned Shanon encryption methods and code C / C algorithms. All related concepts default you know, if not clear concept you call big brother Google offline. ^^ At Shanon encryption algorithm source U with probability distribution table U1 U2 … UN P1 P2 … PN […]

[Algorithm] Count the squares

All taken from the exam: CONTESTS COMPUTING NATIONAL CHILD XIX th - 2013, TABLE B TEST SUBJECT - HIGH SCHOOL FACILITIES. [qads] Threads: For a square table size n × n grid is divided into units, the peak position of the unit squares are called mesh. People want to count the number of squares correspond […]

[Algorithm] Merge sort – Merge Sort

Merge sort algorithm (Merge Sort) is one of the sorting algorithm or used. Nearly identical to quickly sort algorithm (Quick Sort) an arrangement by splitting the original array 2 half, but with Quick Sort element is used as a landmark comparison between Merge Sort is still clearly divided into, sort each array and then "mixed" 2 array rearranged.

[Algorithm] Find the shortest path Dijkstra, Floyd

Update 25/05/2014: Do some of your comments, so I wrote more 1 Dijkstra's algorithm program structure and function by the way also slightly revised code for brighter and more accurate ^^. Update 27/09/2014: additional pascal code of the algorithm here: http://ideone.com/c7J0dq Content Floyd algorithm Dijkstra Algorithm for Advanced Code 2 Update algorithm 14/06/2014: The program […]

[Algorithm] Sieve elements – Prime number Sieve

Sieve element algorithm is given by Eratosthenes to find prime numbers. It is distinguished from other algorithms that examine the prime-style screening, Review all of the required test, the number that is not a prime number, then leave. Appropriate algorithm for the problem of finding all the prime numbers between [the, b] which is particularly effective when the distance between a, b is very large.

[Tree] Binary Tree students – Student Binary Tree

Construction of binary search trees students (key is the student code). Each student student code, name, point. Browse the list of students, More students, remove a student scores less than 4

[Algorithm] Problem number 7

Threads: Code article link: For VOSSEVEN sequence of N characters, Each character is a digit from 0 to 9 Request: For each segment the number 7 consecutive see the child count how many times it appears in the string. String s Input Output Each line contains a corresponding length from low to high frequency of occurrence together with its. Data to ensure […]

[Algorithm] Games with tape number – Linegate

Link threads:vn.spoj.com/problems/LINEGAME/ Recommended Posts: There is a rectangular band is divided into n squares numbered from left to right starting from 1. On the ith square one who recorded a positive integer, i = 1,2,…,n. At each turn, Participants may select an arbitrary number of cells on ice. Suppose that in order from left to right, players selected […]

[Entertainment] Putting things across the river

[Game] After crossing the river the problem of portable lights, some you win, but some of you still can not figure out how to play right up to glory. =)) Putting his introduction to all things across the river to reduce your stress.

[Entertainment] Portable lights across the river

[Game] Xách lights across the river game epitomized algorithm but no less fun, promoting curiosity, clever, people try considered. Have 1 group 5 the last person on the other side of the river bank 1 narrow bridge at night. This relatively weak bridges crossing every turn can only max 2 people. Because it was quite dark so they cross the bridge […]