Embedded Template Library 1.0
Loading...
Searching...
No Matches
fibonacci

Classes

struct  etl::factorial< Value >
struct  etl::fibonacci< Value >

Detailed Description

fibonacci<Value> : Calculates the Nth Fibonacci value.


Class Documentation

◆ etl::factorial

struct etl::factorial
template<size_t Value>
struct etl::factorial< Value >

Defines value as the Nth factorial number.

Template Parameters
ValueThe number to find the factorial value of.

Static Public Attributes

static ETL_CONSTANT size_t value = Value * factorial<Value - 1>::value

◆ etl::fibonacci

struct etl::fibonacci
template<size_t Value>
struct etl::fibonacci< Value >

Defines value as the Nth Fibonacci number.

Template Parameters
ValueThe number to find the Fibonacci value of.

Static Public Attributes

static ETL_CONSTANT size_t value = fibonacci<Value - 1>::value + fibonacci<Value - 2>::value