fork download
  1. // ex2.cpp : Defines the entry point for the console application.
  2.  
  3. #include <iostream>
  4.  
  5. int total(int value1,int value2) {
  6. int totalvalue = value1 + value2;
  7. return totalvalue;
  8. }
  9.  
  10. int main(int argc, char* argv[])
  11. {
  12. float a = 4.5;
  13. int d= 42;
  14. int e = total(6,7);
  15. std::cout << "a = " << a <<std::endl;
  16. std::cout << "d = " << d << " e = " << e << std::endl;
  17. return 0;
  18. }
Success #stdin #stdout 0.01s 2680KB
stdin
Standard input is empty
stdout
a = 4.5
d = 42 e = 13