Help me in solving SEARCHINARR problem

My issue

sol.c:32:1: error: expected declaration or statement at end of input
32 | }
| ^
sol.c:32:1: error: expected declaration or statement at end of input
sol the this error

My code

#include <stdio.h>

int main() {
	// your code goes here
int N, X;
int found = 0;
{
scanf("%d %d, &N, &X ");
int A[N];
for(int i = 0; i< N; i++){
    scanf("%d", &A[i]);
    for(int i =0; i< N; i++){
        if(A[i]==X){
            found =1 ;
            break ;
        }
    }
for (int i = 0; i< N; i++){
    if (A[i]==X){
        found =1;
        break;
    }
    
}
if (found){
    printf("YES\n");
    
} else{
    printf("NO\n");
    return 0 ;
}
}


Learning course: Data Structures & Algorithms using C
Problem Link: Search an element in an array in Data Structures & Algorithms using C