I think you have to spool the output to a text file then run the spool file as a script

spool drop.sql

accept 1st char prompt 'Enter object specification to drop: '
select 'DROP ' ||object_type || ' ' || object_name || ';'
from user_objects
where object_type != 'INDEX' and object_name like upper('&1st')

spool off

then run drop.sql