An open API service indexing awesome lists of open source software.

https://github.com/luigiandrea/gopearls

Programming Pearls in Golang
https://github.com/luigiandrea/gopearls

algorithms benchmarking data-structures go go-benchmarking go-pearls go-programming-pearls go-testing golang pearls tested-solutions testing

Last synced: 2 months ago
JSON representation

Programming Pearls in Golang

Awesome Lists containing this project

README

          

[![Build Status](https://api.travis-ci.org/LuigiAndrea/GoPearls.png?branch=master)](https://travis-ci.org/LuigiAndrea/GoPearls)
[![Build status](https://ci.appveyor.com/api/projects/status/2q7xp7hbr9mmq1gi/branch/master?svg=true)](https://ci.appveyor.com/project/LuigiAndrea/GoPearls)
[![Go Report Card](https://goreportcard.com/badge/github.com/LuigiAndrea/GoPearls)](https://goreportcard.com/report/github.com/LuigiAndrea/GoPearls)

# GoPearls
Programming Pearls in Golang

## How to use


Each problem is identified by its package import path and may be conveniently fetched, built, and installed using the go get command.


### To run all the tests

```go
go test -tags all ./...
```

### To run all the benchmarks

```go
go test -v -bench=. -tags benchmark ./...
```

### Column 1

Problem | Description
------------ | -------------
[1.6.2](https://github.com/LuigiAndrea/GoPearls/tree/master/column1-oyster/bit-vectors)| Bit Vectors
[1.6.3; 1.6.7](https://github.com/LuigiAndrea/GoPearls/tree/master/column1-oyster/sort-file-with-bit-vectors) | Bitmap Sort
[1.6.4](https://github.com/LuigiAndrea/GoPearls/tree/master/column1-oyster/generate-k-random-integer) | Generate k unique random integers
[1.6.9](https://github.com/LuigiAndrea/GoPearls/tree/master/column1-oyster/sparse-vector) | Sparse Vector

### Column 2

Problem | Description
------------ | -------------
[2.6.1](https://github.com/LuigiAndrea/GoPearls/tree/master/column2-aha/anagram)| Anagram
[2.6.2](https://github.com/LuigiAndrea/GoPearls/tree/master/column2-aha/atleast-twice)| Find integer that appears at least twice in sequential file
[2.6.3](https://github.com/LuigiAndrea/GoPearls/tree/master/column2-aha/rotate)| Rotation algorithms
[2.6.8](https://github.com/LuigiAndrea/GoPearls/tree/master/column2-aha/k-element-subset)| K-element subset of the set that sums to at most t

### Column 3

Problem | Description
------------ | -------------
[3.7.2](https://github.com/LuigiAndrea/GoPearls/tree/master/column3-data-structures/linear-recurrence)| Linear recurrence
[3.7.3](https://github.com/LuigiAndrea/GoPearls/tree/master/column3-data-structures/letters)| Banner
[3.7.4](https://github.com/LuigiAndrea/GoPearls/tree/master/column3-data-structures/date-problems)| Date
[3.7.5](https://github.com/LuigiAndrea/GoPearls/tree/master/column3-data-structures/hyphenations)| Hyphenations
[3.7.6](https://github.com/LuigiAndrea/GoPearls/tree/master/column3-data-structures/form-letter-generator)| Form-letter generator
[3.7.8](https://github.com/LuigiAndrea/GoPearls/tree/master/column3-data-structures/seven-segments)| Seven Segments

### Column 4

Problem | Description
------------ | -------------
[4.6.2; 4.6.8; 4.6.10](https://github.com/LuigiAndrea/GoPearls/tree/master/column4-correct-programs/fast-binary-search)| Fast Binary Search
[4.6.5](https://github.com/LuigiAndrea/GoPearls/tree/master/column4-correct-programs/hailstone-number)| Hailstone Number
[4.6.6](https://github.com/LuigiAndrea/GoPearls/tree/master/column4-correct-programs/coffee-can-problem)| Coffee Can Problem
[4.6.7](https://github.com/LuigiAndrea/GoPearls/tree/master/column4-correct-programs/lines-bracket-point)| Two lines that bracket the point
[4.6.9](https://github.com/LuigiAndrea/GoPearls/tree/master/column4-correct-programs/power)| Power Verification
[4.6.11](https://github.com/LuigiAndrea/GoPearls/tree/master/column4-correct-programs/binary-search-declaration)| Binary Search Specific Declaration

### Column 9

Problem | Description
------------ | -------------
[9.5.1](https://github.com/LuigiAndrea/GoPearls/tree/master/column9-code-tuning/sequential-search)| Sequential Search
[9.5.4; 9.5.8](https://github.com/LuigiAndrea/GoPearls/tree/master/column9-code-tuning/maximum-value-array)| Maximum value in array
[9.5.6](https://github.com/LuigiAndrea/GoPearls/tree/master/column9-code-tuning/character-classification)| Character Classification using masks
[9.5.7](https://github.com/LuigiAndrea/GoPearls/tree/master/column9-code-tuning/set-bits)| Count Set Bits
[9.5.10](https://github.com/LuigiAndrea/GoPearls/tree/master/column4-correct-programs/fast-binary-search)| Fast hashing search problem
[9.5.12](https://github.com/LuigiAndrea/GoPearls/tree/master/column9-code-tuning/fast-polynomial)| Faster Polynomial