Start: Jun, 30, 2019 09:00:00
2019年度暑期短学期第十天 助教场
End: Jul, 08, 2019 23:59:00
Time elapsed:
Time remaining:

Problem_ID: C
Result: Accepted
Time: 3ms
Memory: 17580kB
Author: 2018212212028
In contest: 1290

#include<iostream>
#include<cstdio>
#include<algorithm>
#include<cmath>
#include<cstring>
#include<set>
#define ll long long
using namespace std;
const int maxn = 1001000;
const int inf = 0x3f3f3f3f;
#define PI 3.141592653589
#define fr(i,r,l) for(int i=r;i<=l;i++)
ll a[maxn];
ll b[maxn];
int main()
{
	int n;
	cin >> n;
	int s = n;
	int s1, s2, s3;
	s1 = n % 10;
	s2 = n / 10 % 10;
	s3 = n / 100;
	if (pow(s1, 3) + pow(s2, 3) + pow(s3, 3) == n)
	{
		printf("YES\n");
	}
	else printf("NO\n");
}