fork download
  1. // personen.cpp : Defines the entry point for the console application.
  2. //
  3.  
  4. #include "stdafx.h"
  5. #include <iostream>
  6. using namespace std;
  7.  
  8. struct s_person {
  9. char* vorname;
  10. char* nachname;
  11. int alter;
  12.  
  13. };
  14. void person_ein(s_person &person){
  15. char eingabe[200];
  16. cout << "Geben sie bitte den Vornamen ein: ";
  17. cin >> eingabe;
  18. person.vorname = strdup(eingabe);
  19. cout << "Nun der Nachname: ";
  20. cin >> eingabe;
  21. person.nachname = strdup(eingabe);
  22. cout <<"Und das alter: ";
  23. cin >> person.alter;
  24. cout << "vielen Dank.";
  25.  
  26. }
  27. void person_aus(s_person person){
  28. cout << person.vorname << " " << person.nachname << " ist " << person.alter <<"Jahre alt.\n";
  29. }
  30. int _tmain(int argc, _TCHAR* argv[])
  31. {
  32. s_person person1;
  33. person_ein(person1);
  34. person_aus(person1);
  35. system("pause");
  36. return 0;
  37. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.asm:1: error: label or instruction expected at start of line
prog.asm:2: error: label or instruction expected at start of line
prog.asm:4: error: label or instruction expected at start of line
prog.asm:5: error: label or instruction expected at start of line
prog.asm:6: error: parser: instruction expected
prog.asm:8: error: parser: instruction expected
prog.asm:9: error: parser: instruction expected
prog.asm:10: error: symbol `char' redefined
prog.asm:10: error: parser: instruction expected
prog.asm:13: error: label or instruction expected at start of line
prog.asm:14: error: parser: instruction expected
prog.asm:15: error: symbol `char' redefined
prog.asm:15: error: parser: instruction expected
prog.asm:16: error: parser: instruction expected
prog.asm:17: error: parser: instruction expected
prog.asm:18: error: parser: instruction expected
prog.asm:19: error: symbol `cout' redefined
prog.asm:19: error: parser: instruction expected
prog.asm:20: error: symbol `cin' redefined
prog.asm:20: error: parser: instruction expected
prog.asm:21: error: parser: instruction expected
prog.asm:22: error: symbol `cout' redefined
prog.asm:22: error: parser: instruction expected
prog.asm:23: error: symbol `cin' redefined
prog.asm:23: error: parser: instruction expected
prog.asm:24: error: symbol `cout' redefined
prog.asm:24: error: parser: instruction expected
prog.asm:26: error: label or instruction expected at start of line
prog.asm:27: error: symbol `void' redefined
prog.asm:27: error: parser: instruction expected
prog.asm:28: error: symbol `cout' redefined
prog.asm:28: error: parser: instruction expected
prog.asm:29: error: label or instruction expected at start of line
prog.asm:30: error: comma, colon or end of line expected
prog.asm:30: error: comma, colon or end of line expected
prog.asm:31: error: label or instruction expected at start of line
prog.asm:32: error: parser: instruction expected
prog.asm:33: error: parser: instruction expected
prog.asm:34: error: parser: instruction expected
prog.asm:35: error: parser: instruction expected
prog.asm:36: error: parser: instruction expected
prog.asm:37: error: label or instruction expected at start of line
stdout
Standard output is empty