/* compiled stored function */
create or replace
FUNCTION CTOF(i IN NUMBER)
RETURN NUMBER IS
t1 number(4,2);
BEGIN
dbms_output.put_line('Internal display');
dbms_output.put_line((i * 9/5) + 32);
t1:=((i*9/5)+32);
RETURN t1;
END ;

/* calling the stored function with parameter */
DECLARE
C NUMBER(4,2):=0;
BEGIN
C :=CTOF(29.25);
dbms_output.put_line('CTOF returned : '|| C);
END;
