template
double Integral(const func& f, const double& start, const double& end, const double& e) {
double step = .5, result, result0 = f(start), x;
while (true) {
result = .0;
for (x = start; s < end; x += step * (end - start))
result += abs(f(x));
if (result - result0 <= e)
<br> return result;
result0 = result;
step *= .5;
}