public.cpp
来自「Thinking_in_C___2.rar」· C++ 代码 · 共 26 行
CPP
26 行
//: C05:Public.cpp {O}
// From Thinking in C++, 2nd Edition
// at http://www.BruceEckel.com
// (c) Bruce Eckel 1999
// Copyright notice in Copyright.txt
// Public is just like C struct
struct A {
int i;
char j;
float f;
void foo();
};
void A::foo() {}
struct B {
public:
int i;
char j;
float f;
void foo();
};
void B::foo() {} ///:~
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?