#include <iostream>
using namespace std;
int main(void){
    int n,s=0;
    cin>>n;
    for(int i=1;i<=n;i++){
        if(n%i==0){s+=i;}
    }
    if(n==s){cout<<"perfect number";}
    else if(n>s){cout<<"deficient number";}
    else {cout<<"abundant number";}
    return 0;
}

