solve the following question and submit a c++ file not a pdf or image. write a program for: P is one-dimensional array of integers. Write a C++function to efficiently search for a data VAL from P. If VAL is present in the array then the function should return value 1 and 0 otherwise.solve the following question and submit a c++ file not a pdf or image. write a program for: P is one-dimensional array of integers. Write a C++function to efficiently search for a data VAL from P. If VAL is present in the array then the function should return value 1 and 0 otherwise. Show transcribed image text