SHARE
TWEET

Untitled

a guest Jan 19th, 2019 56 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include <iostream>
  2. #include <string.h>
  3. #include <stdio.h>
  4.  
  5. using namespace std;
  6. int m;
  7. char str[80];
  8.  
  9. int rekfunk(int i)
  10. { int val;
  11.    
  12.     if(i<1)
  13.     {
  14.         cout << str <<"i hat den wert 0, Funktion returned 0" << endl;
  15.         return 0;
  16.     }
  17.     cout << str << (i-(m+1))*-1 << ". Funktionsaufruf" << endl;
  18.     cout << str << "i hat hier den Wert: " << i << endl;
  19.     cout << str << "|" << endl;
  20.     cout << str << "|" << endl;
  21.     cout << str << "-----------" << endl;
  22.     strcat (str,"\t");
  23.     val = 7+ rekfunk(i-1);
  24.     cout << str << "Return von " << (i-(m+1))*-1 << ". Funktionsaufruf(" << val << ")" << endl<< endl;
  25.    
  26.    
  27.     return val;
  28. }
  29. void main()
  30. {  
  31.     strcpy (str,"");
  32.     m= 3;
  33.     cout << rekfunk(3) << endl;
  34.     system("PAUSE");
  35. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top