#include <iostream>
using namespace std;

class Stdent {
private:
        int kor;
        int eng;
        int math;
public:
        Stdent(int k ,int e,int m){
            kor = k;
            eng = e;
            math= m;
        };
    float area(){
        float area = (kor + eng + math) / 3;
            return area;
        }
};

int main() {
    Stdent stdent(60,60,59);

    if (stdent.area() >= 60) {
        cout << "합격" <<endl;
    }else{
        cout << "불합격" <<endl;
    }
}

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: