#include <iostream>
using namespace std;
int v[101];
int main()
{
int n, i;
cin >> n;
for (i=1; i<=n; ++i)
cin >> v[i];
int multipli=1;
for (i=1; i<n; ++i)
{
if (v[i]%v[n]) { multipli=0; break; }
}
if (multipli) cout << "DA";
else cout << "NU";
return 0;
}