#include<bits/stdc++.h>
using namespace std;

int main(){
  int N;
  cin >> N;
  int cpN = N;
  int sum = 0;
  
  while(cpN > 0){ 
    sum += cpN % 10;
    cpN /= 10;
  }
  
  if(N % sum == 0)cout << "Yes" << endl;
  else cout << "No" << endl;
 
}
#include<bits/stdc++.h>
#define INF 1e9
#define llINF 1e18
#define MOD 1000000007
#define pb push_back
#define mp make_pair 
#define F first
#define S second
#define ll long long
#define vi vector<ll>
#define vvi vector<vi>
#define BITLE(n) (1LL<<((ll)n))
#define SHIFT_LEFT(n) (1LL<<((ll)n))
#define SUBS(s,f,t) ((s).substr((f),(t)-(f)))
#define ALL(a) (a).begin(),(a).end()
using namespace std;

int main(){
  cin.tie(0);
  ios::sync_with_stdio(false);
  string s;cin>>s;
  for(int i=0;i<s.size()-1;i++){
    if(s[i] == 'A' && s[i+1] == 'C'){
      cout<<"Yes"<<endl;
      return 0;
    }
  }
  cout<<"No"<<endl;
  return 0;
}

