Ads block

Banner 728x90px

Write a c++ program using the conpect of oop to check a number is palindrome or not


#include<iostream> using namespace std ; class Palindrome { private : int n ; public : void input ( ) { cout << "E…
Read more »

Static member function in oop with cpp/++


#include<iostream> using namespace std ; class Static_Learning { private : static int id ; static double result ; public : stat…
Read more »

Memory address of static variable in op with cpp/c++


#include<iostream> using namespace std ; class student { private : static int id ; double res ; public : student ( int ID, dou…
Read more »

Fibonacci series upto n number in cppwith the concept of OOP in CPP/C++


#include<iostream> using namespace std ; class Fibonacci { private : int n ; public : Fibonacci ( int num ) { n = num ; …
Read more »

CPP program using the concept of OOP to check a number is strong or not


#include<iostream> using namespace std ; class Strong { private : int num, number ; public : Strong ( int n ) { num = n ; …
Read more »

This pointer in oop with cpp/c++


#include<iostream> using namespace std ; class This_Pointer { private : int id ; string name ; double result ; public : Thi…
Read more »

Different types of variables in cpp/C++


#include<iostream> using namespace std ; class Variable { public : static int ID ; //Static Variable string name = "ABCD" ;…
Read more »

Simple function with static variable in cpp/c++


#include<iostream> using namespace std ; void display ( ) { static int num = 1 ; int num2 = 0 ; num ++ ; num2 ++ ; c…
Read more »

Static data member in oop with cpp/c++


#include<iostream> using namespace std ; class student { private : static int id ; double res ; public : student ( int ID, dou…
Read more »

Hierarchical inheritance in OOP with CPP/C++


#include <iostream> using namespace std ; class Vehicle /// base class { public : Vehicle ( ) { cout << "This is …
Read more »

Example of encapsulation in OOP with CPP/C++


#include<iostream> using namespace std ; class Encapsulation { private : /// data hidden from outside world int x ; pu…
Read more »

Copy constructor in OOP with CPP/C++


#include<iostream> using namespace std ;   class Numbers { private : int num1, num2, num11, num22 ; public : Numbers (…
Read more »

C++ program using the concept of OOP to find the sum of digits of a number until the sum is reduced to a single digit


/* C++ program using the concept of OOP to find the sum of digits of a number until the sum is reduced to a single digit */ #include<iostream> using n…
Read more »

Palindrome number in cpp using the concept of oop


//Almgir Hossain, Lecturer of CSE, Prime University  #include<iostream> using namespace std ; class Palindrome { private : int n ; public : …
Read more »