fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. void printMessage(int i) {
  5. cout << "Enter number" << endl;
  6. cin >> i;
  7. }
  8. void numberCwadrat(int a) {
  9. int b;
  10. printMessage(b);
  11. a = b * b;
  12. }
  13. int main() {
  14. int c = 1;
  15. int n;
  16. printMessage(n);
  17. numberCwadrat(c);
  18. cout << c << endl;
  19. return 0;
  20. }
Success #stdin #stdout 0.01s 5284KB
stdin
3




stdout
Enter number
Enter number
1