This repository has been archived on 2023-08-20. You can view files and clone it, but cannot push or open issues or pull requests.
NumericalAnalysisModule/1 - Numerical Series Approximation/graficos/erro.cpp

19 lines
470 B
C++
Raw Permalink Normal View History

#include <iostream>
#include <cmath>
int main() {
double vals[] = { 3.1415926029605323,
3.1415926506432696,
3.1415926528764806,
3.1415926535477534,
3.1415926535795631,
3.1415926535891852,
3.1415926535897571,
3.1415926535897851};
std::cout.precision(17);
for(double v : vals) {
std::cout << std::abs(3.14159265358979324 - v);
}
}