У меня есть переменная, значение , объявленная в классе, вход . Я хочу использовать его внутри Main . Вот мой код. < /P>
#include
#include
#include
#include
#include
#include
class input {
public :
int add() {
std::string Type;
std::ifstream typeFile("type.txt");
if (!typeFile.is_open()) {
std::cerr
Подробнее здесь: https://stackoverflow.com/questions/797 ... class-in-c