Empirical
Classes | Namespaces
IndexMap.h File Reference

A simple class to weight items differently within a container and return the correct index. More...

#include "../base/vector.h"

Go to the source code of this file.

Classes

class  emp::IndexMap
 

Namespaces

 emp
 If we are in emscripten, make sure to include the header.
 

Detailed Description

A simple class to weight items differently within a container and return the correct index.

Note
This file is part of Empirical, https://github.com/devosoft/Empirical
Date
2015-2018
Note
Status: BETA
Todo:

Convert to a template that acts as a glorified vector, simplifying random selection?

Should operator[] index by element count or by weight?