개발자 노트

C++ 본문

▶ INBOX ◀

C++

heeyam 2016. 10. 10. 20:49
반응형

#include <iostream>

using namespace std;


typedef struct Body

{

int tall;

int weight;

}body;


int main()

{

body person[2];



cout << "민수의 키와 몸무게 입력 ";

cin >> person[0].tall >> person[0].weight;



cout << "기영이의 키와 몸무게 입력 ";

cin >> person[1].tall >> person[1].weight;


if(person[0].tall > person[1].tall && person[0].weight > person[1].weight)

{

cout << 1;

}

else{

cout << 0;

}

return 0;

}

반응형
Comments