C++ Programming - Objects and Classes - Discussion
Discussion Forum : Objects and Classes - General Questions (Q.No. 4)
4.
Which of the following two entities (reading from Left to Right) can be connected by the dot operator?
Discussion:
5 comments Page 1 of 1.
Prashant Patel said:
10 years ago
What about the static member I mean System.out?
Static member can also be associated with this operator. Thus making option C potential candidate.
Static member can also be associated with this operator. Thus making option C potential candidate.
Naina sharma said:
10 years ago
A class object and member of that class can be dot operator because the value of the variable that is declared in that class accessed of by dot operator.
Akhila s said:
10 years ago
The dot operator applied to actual object, so class object and a member of that class can be connected by dot operator.
Anita said:
1 decade ago
A class object and a member of that class can be connected by dot operator because the value of the variable that is declared in that class can be accessed by the object of that class.
Bhagchand said:
1 decade ago
Because object of that class provide facility to access value of variable that declare in class by DOT(.) operator
Ex:- class sum
{
int a,b;
sum(int x,int y)
{
this.a=x;//(.)DOT operator between object and member of that class
this.b=y;
}
here this is object of current class
Ex:- class sum
{
int a,b;
sum(int x,int y)
{
this.a=x;//(.)DOT operator between object and member of that class
this.b=y;
}
here this is object of current class
Post your comments here:
Quick links
Quantitative Aptitude
Verbal (English)
Reasoning
Programming
Interview
Placement Papers