title: PLS-00103: Encountered the symbol "BEGIN"
body: <p>I want to create a function that return the power of a given number, the SQL developer keep giving me this error : </p>
  
  <blockquote>
    <p>PLS-00103: Encountered the symbol "BEGIN"</p>
    
    <p>Errors: check compiler log</p>
  </blockquote>
  
  <p>Here's my code</p>
  
  <pre><code>CREATE OR REPLACE FUNCTION Power(x NUMBER,n NUMBER) return Number IS
      Pow number;
      i number;
      BEGIN
      Pow:=1;
  
      FOR i IN 1..n LOOP
      Pow:=Pow*x;
      END LOOP;
      return Pow;
      END Power;
  
      BEGIN
      DBMS_OUTPUT.PUT_LINE(Power(2,3));
      END;
  </code></pre>
  
  <p>Thank you for helping me I really appreciate it.</p>