From d1dba197cae53aaff3616df61fd1a0d8d5f26f97 Mon Sep 17 00:00:00 2001 From: austinlujan Date: Thu, 21 Mar 2024 03:53:27 -0700 Subject: assignment completed and tested --- Project1/helpers.h | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) (limited to 'Project1/helpers.h') diff --git a/Project1/helpers.h b/Project1/helpers.h index 6f70f09..606bef3 100644 --- a/Project1/helpers.h +++ b/Project1/helpers.h @@ -1 +1,13 @@ -#pragma once +#ifndef FUNCTIONS_H +#define FUNCTIONS_H + +#include + +class RecursiveFunctions { +public: + static long factorial(int n); // integer n returns its factorial as a long + static int fibonacci(int n); // integer n returns the nth term in the fibonacci sequence + static double power(double base, int exponent); //double base and an integer exponent returns base raised to the exponent power +}; + +#endif -- cgit v1.2.3