Advertisement
Guest User

Untitled

a guest
Nov 25th, 2014
169
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.32 KB | None | 0 0
  1. static double newton(int x, int y)
  2. {
  3.  
  4. if(x > 33 || y > 33)
  5. {
  6. cout << -1 <<;
  7. }
  8. else if(x == 0 || x == y)
  9. {
  10. return 1;
  11. }
  12. else if(x>0 && y>0 && y>x)
  13. {
  14. return newton(x-1, y-1) + newton(x-1,y);
  15. }
  16. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement