commit faaa7dc980a80895b703775d18132eb6db105021
Author:     Mattias Andrée <[email protected]>
AuthorDate: Mon Jul 25 17:08:51 2016 +0200
Commit:     Mattias Andrée <[email protected]>
CommitDate: Mon Jul 25 17:08:51 2016 +0200

    Exercise solutions: the return type should be on the line above the 
function name, like in the rest of the manual
    
    Signed-off-by: Mattias Andrée <[email protected]>

diff --git a/doc/exercises.tex b/doc/exercises.tex
index 160067d..e004f0a 100644
--- a/doc/exercises.tex
+++ b/doc/exercises.tex
@@ -336,7 +336,8 @@ $2^p \equiv 2 ~(\text{Mod}~p)$. This gives us
 
 \vspace{-1em}
 \begin{alltt}
-enum zprimality ptest_fast(z_t p)
+enum zprimality
+ptest_fast(z_t p)
 \{
     z_t a;
     int c = zcmpu(p, 2);
@@ -363,7 +364,8 @@ such that $1 < a < p$) if $t < 0$.
 
 \vspace{-1em}
 \begin{alltt}
-enum zprimality ptest_fermat(z_t witness, z_t p, int t)
+enum zprimality
+ptest_fermat(z_t witness, z_t p, int t)
 \{
     enum zprimality rc = PROBABLY_PRIME;
     z_t a, p1, p3, temp;
@@ -405,7 +407,8 @@ enum zprimality ptest_fermat(z_t witness, z_t p, int t)
 
 \vspace{-1em}
 \begin{alltt}
-enum zprimality ptest_llt(z_t n)
+enum zprimality
+ptest_llt(z_t n)
 \{
     z_t s, M;
     int c;
@@ -505,7 +508,8 @@ but for efficiency and briefness, we will use
 
 \vspace{-1em}
 \begin{alltt}
-void golden_pow(z_t r, z_t n)
+void
+golden_pow(z_t r, z_t n)
 \{
     if (zsignum(n) <= 0)
         zsetu(r, zcmpi(n, -1) >= 0);

Reply via email to