useCallback is a react hook which is used for the memorisation of the callback
function as we know in react every component re-rendered so its function also re
created and so avoid the recreation of complex functions we used the concept of
useCallback which takes a function as a arguement and a dependency list for
which condition the component are going to create itself;