Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
#26
#include <iostream> #include <string> using namespace std; void czyscBufor (){ cin.clear(); cin.sync(); } void wczytajOsobe(string im, string naz, int wiek){ cout << endl << "Podaj imiÄ™"; //czyscBufor(); getline(cin, im); cout << endl << "Podaj nazwisko"; //czyscBufor(); getline(cin, naz); do { cout << endl << "Wiek: "; //czyscBufor(); cin >> wiek; } while (cin.good()); cout << im << naz << wiek; } void wypiszOsobe(string im, string naz, int wiek){ cout << endl << im << " " << naz << "," << wiek; } int main() { std::string imie[ 1 ]; std::string nazwisko[ 1 ]; int wiek[ 1 ]; for( int i = 0; i < 1; i++ ) wczytajOsobe( imie[ i ], nazwisko[ i ], wiek[ i ] ); for( int i = 0; i < 1; i++ ) wypiszOsobe( imie[ i ], nazwisko[ i ], wiek[ i ] ); return 0; }
run
|
edit
|
history
|
help
0
Double_wrapper vc++
Insertion vs Sort
zero size std::array parameter
#32
Copy initialization: overload resolution issue
Dynamically sized array at end of struct
msvc set-terminate
Template function declaration to avoid usage of template in T::template f<int>()
accessibility on in-class typedefs
upper_bound With binary_function Visual Studio 2008 Bug?