The exit is implicit; It exits when it runs out of rows in the cursor. However, you can add an additional explicit exit. Please see the examples below.
scott@ORA92> set serveroutput on
scott@ORA92> -- without explicit exit:
scott@ORA92> begin
2 for rec in (select * from dept order by deptno)
3 loop
4 dbms_output.put_line (rec.deptno);
5 end loop;
6 end;
7 /
10
20
30
40
PL/SQL procedure successfully completed.
scott@ORA92> -- with explicit exit:
scott@ORA92> begin
2 for rec in (select * from dept order by deptno)
3 loop
4 dbms_output.put_line (rec.deptno);
5 exit when rec.deptno = 30;
6 end loop;
7 end;
8 /
10
20
30
PL/SQL procedure successfully completed.