No older revisions available
No older revisions available
~cpp
#include <iostream>
using namespace std;
void show_menu();
int
in();
void out();
int arr[1000];
int i,j;
void main()
{
show_menu();
int choice;
cin >> choice;
while(cin>>choice)
{
if (choice==1)
{
in();
continue;
}
else if (choice==2)
;
else if (choice==3)
out();
}
}
void show_menu()
{
cout << " 1 : 입력"<<"\t"<<" 2 : 빼기"<<"\t"<< " 3 : 보여주기"<<endl;
}
int in()
{
cout << "숫자를 입력하세요.. "<< endl;
int a;
cin >> a;
arr[i] = a;
return i;
}
void out()
{
int k;
for (k=0; k<i+1; k++)
{
cout << arr[k];
}
}