First Step
Object-Oriented Programming (OOP) is a technique of computer programming model that organizes software design around data, or objects, rather than functions and logic. We can define an object that as a data field which has unique attributes and behaviour.
Second Step
Try to know What Is Object-Oriented Programming concepts?
To better known OOP’s concept try to relate with the real world problems and how real-world problems can be solved by OOP’s.
Why study of Object-Oriented Programming is necessary and important to learn?
Know the limitations and advantages of OOP.
Third Step
Now understand above steps try to focus on Structure of Object-Oriented Programming Language as below:-
· What is the definition of Class.
· What is definition Object.
· Know the difference between Class and Object.
· How to use of Classes and Object in program.
· Try to know real-world scenario of class and object.
· Understand all Access Modifiers (public, private, protected, etc.) in OOP’s.
Fourth Step
Important Keywords in OOPs to learn and understand:
Final Keyword
Explicit keyword
This Keyword
new Keyword
const keyword
super keyword etc…
Example:-
#include <iostream>
#include <string>
using namespace std;
class MyExample
{
public:
int numdata;
string stringdata;
};
int main()
{
MyExample myObj;
myObj.stringdata = "Your value is...";
myObj.numdata = 108;
cout << myObj.stringdata;
cout << myObj.numdata << "\n";
return 0;
}
For More Information:
Call us @ +91 9825618292
Visit us @ http://tccicomputercoaching.com
ความคิดเห็น