*OverviewWrite a program that will simulate a lottery.*ProcessingThe main function for this program is pretty basic. It should start by creating two arrays that can hold a maximum of 5 integer elements. One of the arrays will hold the winning lottery numbers, while the other will hold the users selected lottery numbers.As with previous programs, the random number generator will be used. So make sure to seed the random number generator by using srand in main().Call the getWinners function that is described below to fill the array of winning lottery numbers.Display a title such as Pick 5 Lottery.Call the getChoices function that is described below to fill the array of user selected lottery numbers.Call the sortArray function two times. One call should sort the array of winning numbers. The other call should should sort the array of user selected numbers.Finally, call the printWinners function that is described below to display the res
ults of the lottery drawing.*The FunctionsFor this program, two functions have been provided. They can be found here: londonessays.com functions are:bool isDuplicate( int array[], int arraySize, int searchNum )This function will check to see if an integer value has already been placed into an array.It takes three arguments: the array of integers to be searched, the number of values in the array of integers, and the integer value to search for in the array of integers.It returns a boolean value of true if searchNum is found in array or a boolean value of false if searchNum is not in found in array.int getUserNum( int upperBd )This function will get a number between 1 and an upperbound, inclusive.It takes one argument: the integer upperbound.It returns an integer: the user selected value that is between 1 and the passed in upperbound.Note: before calling this function, execute a cout statement to display a prompt to the user. For example:int num;