📄 sl203.cpp
字号:
// sl203.cpp : Defines the entry point for the console application.
//
#include "stdafx.h"
#include "iostream.h"
struct employees
{
int id;
char name[20];
char sex[2];
};
int main()
{
employees emp1,emp2;
cout<<"输入emp1数据:"<<"\n";
cout<<"id:";
cin>>emp1.id;
cout<<"name:";
cin>>emp1.name;
cout<<"sex:";
cin>>emp1.sex;
cout<<"输入emp25数据:"<<"\n";
cout<<"id:";
cin>>emp2.id;
cout<<"name:";
cin>>emp2.name;
cout<<"sex:";
cin>>emp2.sex;
cout<<"输出emp1:"<<"\n";
cout<<"id="<<emp1.id<<"\n";
cout<<"name="<<emp1.name<<"\n";
cout<<"sex="<<emp1.sex<<"\n";
cout<<"输出emp2:"<<"\n";
cout<<"id="<<emp2.id<<"\n";
cout<<"name="<<emp2.name<<"\n";
cout<<"sex="<<emp2.sex<<"\n";
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -