class tag

88 questions


1 answers
105 views
0
C++ class template

#include <iostream>using namespace std;template <typename T>class Stack {private: T* mData; int mMaxSize, mTop;public : Stack(); Stack(int _size); Stack(const Stack& _data); ~Stack(); ...

2 years ago

3 answers
92 views
0
Simple class inheritance question

It's a simple question.class CObj{ virtual int Add();};class CUnit :public CObjs{ virtual int Add(); virtual void Check();};If there is a simple inheritance structure as follows:Can I normally access ...

2 years ago

1 answers
87 views
0
Java Class Object List (ArrayList)

I'm trying to create a banking system.Using ArrayList and class systems, he made it possible for several people to open their accountsThe error keeps coming up at the part where I check the card numbe...


1 answers
63 views
0
css virtual class : partial spacing

Some text.Some other text.One more text1)p:not(.classy) { color: red; }body :not(p) { color: green; }2)p:not(.classy) { color: red; }body:not(p) { color: green; }Next to the body: Is there a reason wh...

2 years ago

1 answers
125 views
0
(Python3) What is the difference between super() and super(A, self)?

class A: def __init__(self): print(A)class B(A): def __init__(self): super().__init__()b = B()class A: def __init__(self): print(A)class B(A): def __init__(self): super(B, self).__init__()b = B()T...

2 years ago

1 answers
76 views
0
What should I do to add code to the Rectangle class so that the code called Rectangle; in main() can be executed?

class Point{public: int x, y; Point(){} Point(int xx, int yy) { x = xx; y = yy; }};class Rectangle{ Point p; int width, height;public: Rectangle(int x, int y, int w, int h) { p.x = x; p.y = y; width...

2 years ago

1 answers
58 views
0
Why is it getting an error in Java?

I'm making a Tetris game. If you execute the code below, the message Shape is not an enclosing class appears. public class Test { public static void main(String[] args) { Shape s = new Shape.ZShape()...

2 years ago

1 answers
76 views
0
I have a question about JAVA compilation.

I have a question during Java coding.While a method written with JAVA is running I would like to ask if there is any way to compile a specific java file.In Eclipse, etc., it is not a compile commandI ...

2 years ago

1 answers
105 views
0
Is there a private variable in Python's class?

I'm using Java and learning Python by reading Bruce Eckels' Python 3 Patterns, Recipes and IdiomsWhile reading about the class, Python found that just using it in the constructor creates variables wit...

2 years ago

1 answers
98 views
0
Static class member in Python

Can I create a static member variable or function in the Python class? What grammar should I use?

« - 6 - »

© 2024 OneMinuteCode. All rights reserved.