What do you want to save?
Add Code snippet
New code examples
-
C++ 2021-11-04 20:02:22
function overriding in oop c++
#include<iostream> using namespace std; class Base { public: virtual void show() // virtual function { cout << "Base class"; } }; class Derived:public Base { public: void show() { cout << "Derived Class"; ... Add solution -
Other 2021-11-03 07:18:08
The instance member 'data' can't be accessed in an initializer.
you can use the getter methods that can access these class objects inside the methods. class AppTheme { final Color blueColorHexCode = Color(0xff3d63ff); //App Bar Text TextTheme get appBarTextTheme { return TextTheme( headline1: Googl... Add solution -
Other 2021-10-28 18:11:06
what is oop concept
OOP focuses on the objects that are required to be manipulated instead of logic. - It makes development and maintenance easier - It provides data hiding - It provides ability to simulate real-world - less memory and organized - reusable OOP language fol... Add solution -
Other 2021-10-27 17:38:10
what is polymorphism in oops
Polymorphism is the method in an object-oriented programming language that performs different things as per the object's class, which calls it. With Polymorphism, a message is sent to multiple class objects, and every object responds appropriately accordi... Add solution -
Other 2021-10-26 08:36:12
how to use list of item in modelMapper
public class ObjectMapperUtils { private static ModelMapper modelMapper = new ModelMapper(); /** * Model mapper property setting are specified in the following block. * Default property matching strategy is set to Strict see {@link Mat... Add solution -
C++ 2021-10-25 18:01:11
virual function
#include <iostream> using namespace std; class Enemy { public: virtual void Attack() {} }; class Ninja : public Enemy { public: void Attack() { cout << "ninja attack" << endl; } }; class Monster :public Enemy { void ... Add solution -
Other 2021-10-22 06:38:14
The instance member 'blueColorHexCode' can't be accessed in an initializer.
you can use the getter methods that can access these class objects inside the methods. class AppTheme { final Color blueColorHexCode = Color(0xff3d63ff); //App Bar Text TextTheme get appBarTextTheme { return TextTheme( headline1: Googl... Add solution -
Python 2021-10-17 17:14:04
@classmethod vs @staticmethod vs "plain" methods
# @classmethod vs @staticmethod vs "plain" methods # What's the difference? class MyClass: def method(self): """ Instance methods need a class instance and can access the instance through `self`. ... Add solution