func_code_string: #include <bits/stdc++.h>   using namespace std;   int n, m, l[103], a[103];   int num[103];   vector<int> v;   int main() {     scanf( %d%d , &n, &m);     for (int i = 1; i <= m; i++) scanf( %d , &l[i]);     for (int i = 1; i < m; i++) {       int t = l[i + 1];       while (t <= l[i]) t += n;       if (a[l[i]] && a[l[i]] != t - l[i]) {         printf( -1 n );         return 0;       }       if (!a[l[i]]) {         a[l[i]] = t - l[i];         num[a[l[i]]]++;       }     }     for (int i = 1; i <= n; i++)       if (num[i] > 1) {         printf( -1 n );         return 0;       } else if (!num[i])         v.push_back(i);     for (int i = 1; i <= n; i++) {       if (!a[i]) a[i] = v.back(), v.pop_back();       printf( %d  , a[i]);     }     return 0;   }   