I have a question about this particular code.
The structs would not save the value entered by the user into its class' attributes.
If you do not understand what i am talking about, please compile the code below. Can someone kindly explain what is the problem and how to fix it? Thank you for your time.
using namespace std;
cout<<"Insert int a";
cout<<"Insert string b";
cout<<c.ret_a()<<endl<<c.ret_b(); //It should output the same value inputted by the user
// but it shows nonsense. why is it so?