⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 open.cpp

📁 Since the field of object oriented programming is probably new to you, you will find that there is a
💻 CPP
字号:
                                  // Chapter 5 - Program 1 - OPEN.CPP
#include <iostream.h>

struct one_datum 
{
   int data_store;
};

int main()
{
one_datum dog1, dog2, dog3;
int piggy;

   dog1.data_store = 12;
   dog2.data_store = 17;
   dog3.data_store = -13;
   piggy = 123;

   cout << "The value of dog1 is " << dog1.data_store << "\n";
   cout << "The value of dog2 is " << dog2.data_store << "\n";
   cout << "The value of dog3 is " << dog3.data_store << "\n";
   cout << "The value of piggy is " << piggy << "\n";

   return 0;
}




// Result of execution
//
// The value of dog1 is 12
// The value of dog2 is 17
// The value of dog3 is -13
// The value of piggy is 123

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -