hdu1418 欧拉公式

hdu1418抱歉

欧拉公式:

F(面数)+V(顶点数)-E(楞数)=2
#include <iostream>

using namespace std;

int main()
{   long long n,m;
    while(cin >> n >> m){
        if(n == 0&& m == 0)
            break;
        long long ans = 0;
        ans = n + (m-2);
        cout << ans << endl;
    }
    return 0;
}

 

posted on 2016-04-28 12:13  Tob's_the_top  阅读(144)  评论(0编辑  收藏  举报

导航