由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Programming版 - C++菜鸟问题请教: class versus structure.
相关主题
one question about struct请问C++小白问题
The C++ questions I've been askedC++ Q96: function inheritance (转载)
不明白C++的一个地方What is the difference between class and struct?
one more interview question定义linked list最后一行什么意思?
C++ Q09: delete dynamic arrayWhy oop is bad?
两个看来相似的问题C++ (with MATLAB engine) compiling problem under Linux systerm
protected class member in C++ask a C++ inheritance question
about struct and class in c++关于c++ classes的interview test
相关话题的讨论汇总
话题: class话题: structure话题: c++话题: inherited话题: struct
进入Programming版参与讨论
1 (共1页)
S*****H
发帖数: 90
1
Is a structure just a class without any member functions?
Thanks a lot,
g*****g
发帖数: 34805
2
struct is a class with everything public.
It can have member function.

【在 S*****H 的大作中提到】
: Is a structure just a class without any member functions?
: Thanks a lot,

s*******e
发帖数: 28
3
should be: struct is a class with everything public by default.
It can also have private mems.

【在 g*****g 的大作中提到】
: struct is a class with everything public.
: It can have member function.

G*****m
发帖数: 5395
4
default permission, public vs private

Is a structure just a class without any member functions?
Thanks a lot,

【在 S*****H 的大作中提到】
: Is a structure just a class without any member functions?
: Thanks a lot,

k**m
发帖数: 222
5
another thing:
if inherited,
class is private inherited by default.
struct is public inherited by default.
1 (共1页)
进入Programming版参与讨论
相关主题
关于c++ classes的interview testC++ Q09: delete dynamic array
C++ cast 小结两个看来相似的问题
about multiple inheritanceprotected class member in C++
How to check the virtual function table size?about struct and class in c++
one question about struct请问C++小白问题
The C++ questions I've been askedC++ Q96: function inheritance (转载)
不明白C++的一个地方What is the difference between class and struct?
one more interview question定义linked list最后一行什么意思?
相关话题的讨论汇总
话题: class话题: structure话题: c++话题: inherited话题: struct