https://github.com/briwilcox/algos
Learning go through algorithms
https://github.com/briwilcox/algos
binary-trees bubble-sort insertion-sort quicksort selection-sort
Last synced: 27 days ago
JSON representation
Learning go through algorithms
- Host: GitHub
- URL: https://github.com/briwilcox/algos
- Owner: briwilcox
- License: mit
- Created: 2016-05-07T04:26:37.000Z (almost 10 years ago)
- Default Branch: master
- Last Pushed: 2016-05-15T21:09:02.000Z (over 9 years ago)
- Last Synced: 2024-06-20T02:11:58.347Z (over 1 year ago)
- Topics: binary-trees, bubble-sort, insertion-sort, quicksort, selection-sort
- Language: Go
- Homepage:
- Size: 27.3 KB
- Stars: 6
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Algorithms
Reviewing algorithms, learning go. Images from wikipedia.
## Search
* Binary Search

## Sorting
### Exchange Sorts:
* Bubble Sort

* Odd Even Sort

* Quicksort

### Selection Sorts
* Selection Sort

### Insertion Sorts
* Insertion Sort

### Merge Sorts
* Merge Sort

## Primality
* Naive Primality
* Sieve of Eratosthenes

## Graphs
### Trees
#### Binary trees
Creation, insertion, searching, and simultaneously searching via go routines. Taken from golang.org

# Outputs
## Search
### Binary Search
Binary Search:
* Search Space: [0 1 2 3 4 5 6 7 8 9]
* a[ 9 ] = 9
Binary Search:
* Search Space: [0 1 2 3 4 5 6 7 8 9]
* a[ 2 ] = 2
Binary Search:
* Search Space: [0 1 2 3 4 5 6 7 8 9]
* 15 was not found
Binary Search:
* Search Space: [0 1 2 3 4 5 6 7 8 9]
* a[ 5 ] = 5
Binary Search:
* Search Space: [0 1 2 3 4 5 6 7 8 9]
* 10 was not found
## Sort
### Quicksort
Unsorted:
* [9 8 7 6 5 4 3 2 1 0]
Sorted via Quicksort:
* [0 1 2 3 4 5 6 7 8 9]
Unsorted:
* [0 9 3 5 4 1 6 7 8 2]
Sorted via Quicksort:
* [0 1 2 3 4 5 6 7 8 9]