mirror of
https://github.com/TheAlgorithms/C-Plus-Plus.git
synced 2026-02-08 04:59:21 +08:00
made functions static to files
*BUG* in CPP lint github action
This commit is contained in:
@@ -1,10 +1,11 @@
|
||||
#include <cmath>
|
||||
#include <iostream>
|
||||
|
||||
float eq(float i) {
|
||||
static float eq(float i) {
|
||||
return (std::pow(i, 3) - (4 * i) - 9); // original equation
|
||||
}
|
||||
float eq_der(float i) {
|
||||
|
||||
static float eq_der(float i) {
|
||||
return ((3 * std::pow(i, 2)) - 4); // derivative of equation
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user