Codeforces Round #436 (Div. 2) Make a Permutation!

#include 
#define pb push_back
#define mp make_pair

using namespace std;
int a[200005];
int vis[200005];//       
bool vis1[200005];//        
int main()
{
    int n;
    scanf("%d",&n);
    memset(vis,0,sizeof(vis));
    memset(vis1,0,sizeof(vis1));
    for(int i=1;i<=n;i++)
        scanf("%d",&a[i]),vis[a[i]]++;
        int cnt=0;
        int j=1;
    for(int i=1;i<=n;i++)
    {
        if(vis[i]>0)continue;
        for(;j<=n;j++)
        {
            if(vis[a[j]]>1)
            {
                if(a[j]

좋은 웹페이지 즐겨찾기