Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int main ()
- {
- int n;
- float a, b;
- a = ?;
- b = ?;
- float h = (b - a)/n;
- float f = 0;
- for(int i=0;i<n;i++){
- float c = a + (i - 1/2) * h;
- f = f + c/(c*c);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement