Problem Code:CHNGIT
Contest Code:Practice
Status:Correct Answer
Language : C(NOTE : Try a few times yourself before moving to the solution)
Problem Code:
CHNGITContest Code:Practice
Status:
Correct Answer
#include <stdio.h>
int main(void) {
int t;
scanf("%d",&t);
while(t--)
{
int n,cnt = 0;
int k = 0;
scanf("%d",&n);
int A[n];
for(int i=0;i=cnt)
{
cnt=k;
}
}
printf("%d\n",(n - cnt));
}
return 0;
}
No comments:
Post a Comment