parent shell is waiting upon the child shell

Hi,
I haev to devlop a script which when executed will take in a sudo privelege and run a set of commands then will go back to parent shell and execute the rest of the command

But the problem I am facing is that when the script is executed it takes the sudo privelege but it waits for the user to enter commands to execute but once we exit the sudo user it continues with the rest of the script

can somebody help me out