fork(1) download
  1. #include<string>
  2. #include<iostream>
  3.  
  4. using std::string;
  5. using namespace std;
  6.  
  7. class Connection {
  8. public:
  9. Connection();
  10. string conexao;
  11. string getConexao();
  12. };
  13.  
  14. Connection::Connection() {
  15. conexao = "sete de setembro";
  16. }
  17.  
  18. string Connection::getConexao() {
  19. cout << conexao << endl;
  20. return conexao;
  21. }
  22.  
  23. int main(void) {
  24. Connection con;
  25. con.getConexao();
  26. return 0;
  27. }
Success #stdin #stdout 0s 3460KB
stdin
Standard input is empty
stdout
sete de setembro