top of page

소스 코드 제출

공개·회원 52명

20250711

//#include<stdio.h>

//int n, m,q[1000005][2]={}, top=-1,b=-1,i,j,arr[1005][1005]={},k=1,cnt=0;

//int main()

//{

// scanf("%d %d", &m, &n);

// for(i=0;i<=n+1;i++)

// {

// for(j=0;j<=m+1;j++)

// {

// if (i<1 || j<1 || i>n || j>m)

// {

// arr[i][j]=-1;

// }

// else

// {

// scanf("%d", &arr[i][j]);

// if (arr[i][j]==1)

// {

// top++;

// q[top][0]=i;

// q[top][1]=j;

// }

// }

// }

// }

// while(top!=b)

// {

// cnt ++;

// int max = top;

// for(i=b+1;i<=max;i++)

// {

// b++;

// int y=q[b][0];

// int x=q[b][1];

// if (arr[y+1][x]!=-1 && arr[y+1][x]!=1)

// {

// arr[y+1][x]=1;

// top++;

// q[top][0]=y+1;

// q[top][1]=x;

// }

// if (arr[y-1][x]!=-1 && arr[y-1][x]!=1)

// {

// arr[y-1][x]=1;

// top++;

// q[top][0]=y-1;

// q[top][1]=x;

// }

// if (arr[y][x+1]!=-1 && arr[y][x+1]!=1)

// {

// arr[y][x+1]=1;

// top++;

// q[top][0]=y;

// q[top][1]=x+1;

// }

// if (arr[y][x-1]!=-1 && arr[y][x-1]!=1)

// {

// arr[y][x-1]=1;

// top++;

// q[top][0]=y;

// q[top][1]=x-1;

// }

// }

//// for(i=0;i<=n+1;i++)

//// {

//// for(j=0;j<=m+1;j++)

//// {

//// printf("%2d ", arr[i][j]);

//// }

//// printf("\n");

//// }

//// printf("\n\n%d\n", cnt);

// }

// for(i=1;i<=n;i++)

// {

// for(j=1;j<=m;j++)

// {

// if (arr[i][j]==0)

// {

// printf("-1");

// return 0;

// }

// }

// }

// printf("%d", cnt-1);

// return 0;

//}

2회 조회
주소 : 경기도 용인시 광교중앙로 302 블루 스퀘어 602호
연락처 : 031) 216 - 1546 ,     031) 215 - 1546
사업자등록번호 : 465-92-00916
​학원 등록 제 4603호
bottom of page