const tab = (f, a, b, h) => { return Array.from( { length: Math.ceil((b - a) / h) + 1 }, (v, i) => f(a + (i * h))).reduce((a, c) => a += c, 0 ) }
const tab = (f, a, b, h) => Array.from({length:Math.ceil((b-a)/h)+1}, (v,i) => f(a+(i*h))).reduce((a,c) => a+=c,0)- const tab = (f, a, b, h) => {
- return Array.from(
- {
- length: Math.ceil((b - a) / h) + 1
- },
- (v, i) => f(a + (i * h))).reduce((a, c) => a += c, 0
- )
- }