hi, i want to ask..
is it can to get an input from the user by only call the class object?
here's the code :
#include <iostream>
class Time{
private:
int time;
int minute;
int sec;
...
};
void main(){
Time t;
cin >> t;
cout << "The time is : " << t << endl;
}
Is that code wrong or true, but need some additional parts?
please give me a detail and simple explanation because i'm still a newbie. Thank You.