#include #include using namespace std; using namespace numbers; int main(){ cin.tie(0)->sync_with_stdio(0); cin.exceptions(ios::badbit | ios::failbit); int n; cin >> n; vector a(n); copy_n(istream_iterator(cin), n, a.begin()); for(auto i = 1; i < n; ++ i){ if((a[i] % n + n) % n != (a[0] % n + n) % n){ cout << "No\n"; return 0; } } cout << "Yes\n"; return 0; } /* */ //////////////////////////////////////////////////////////////////////////////////////// // // // Coded by Aeren // // // ////////////////////////////////////////////////////////////////////////////////////////