Please solve my error in code

there is many issues in your code
I resolved all of them

  1. no need to make check function
  2. if element found return 1 else you have to return 0
  3. to find the element you have to take it from user and then pass it in function

Modified code:

i hope this helps ,
If you have further doubt,
feel free to ask

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.