From 75f2d11c824c3f64ca97821c83fe838ecaa6e986 Mon Sep 17 00:00:00 2001 From: Linkus000 Date: Sun, 2 Apr 2017 12:40:59 +0200 Subject: [PATCH] Change arrays indicating visitiveness of nodes to bool[] from int[] --- chapter12.tex | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/chapter12.tex b/chapter12.tex index 5cf87bc..ae8be4e 100644 --- a/chapter12.tex +++ b/chapter12.tex @@ -133,7 +133,7 @@ vector v[N]; \end{lstlisting} and also maintains an array \begin{lstlisting} -int z[N]; +bool z[N]; \end{lstlisting} that keeps track of the visited nodes. Initially, each array value is 0, @@ -323,7 +323,8 @@ of the queue is the next node to be processed. In addition, the code uses arrays \begin{lstlisting} -int z[N], e[N]; +bool z[N]; +int e[N]; \end{lstlisting} so that the array \texttt{z} indicates which nodes the search has already visited