are you talking here about sqlplus PAUSE command?
If so, you may try to use ACCEPT command instead for obtaining substitution variable. However, you will have to treat its value in the code manually - I am not aware about any way for conditional code execution/termination in sqlplus. Depending on exact "script" language, you may do that decision on operating system level.

>Based on the accept value, I can make an IF..THEN..ELSE statement, can't I?
ACCEPT is SQLPLUS command & SQLPLUS does not have/support IF THEN ELSE construct.
PL/SQL is different from SQL which is different from SQLPLUS

OK, let's see how it works. User is asked whether he/she wants to continue script execution and answer Y or N. If the answer is Y, script does "something" (for example, lists contents of Scott's DEPT table). If the answer is N, script exits.

Yes but you achieve a different thing that you asked for even if it does what you want it does, it is not what you asked: "But wether or not to continue to execute the script".
Here whatever is the answer you continue the script.

This is why it is better to ask what you want to achieve (the final goal) and not how to achieve the way you think to achieve your goal.