diff --git a/debugging/lecture/debugging.tex b/debugging/lecture/debugging.tex index c8167e2..a61c9fb 100644 --- a/debugging/lecture/debugging.tex +++ b/debugging/lecture/debugging.tex @@ -439,11 +439,11 @@ that help to solve the problem. steps for correctness. \item Call for help and explain the program to someone else. When you do this, start at the beginning and walk through the program line by - line. Often it is not necessary that the other person is a - programmer or exactly understands what is going on. Often, it is the + line. Often, it is not necessary that the other person is a + programmer or exactly understands what is going on. Rather, it is the own reflection on the problem and the chosen approach that helps - finding the bug. (This strategy is also known as \codeterm{Rubber - duck debugging}. + finding the bug (This strategy is also known as \codeterm{Rubber + duck debugging}). \end{enumerate} @@ -492,15 +492,16 @@ The toolbar of the editor offers now a new set of tools for debugging: \item \textbf{Step} --- Execute the next command and stop. \item \textbf{Step in} --- If the next command is a function call, step into it and stop at the first command. -\item \textbf{Step out} --- If the next command is a function call, - proceed until the called function returns, then stop. +\item \textbf{Step out} --- Suppose you entered a function with + \emph{step in}. \emph{Step out} will continue with the execution and + stop once you are back in the calling function. \item \textbf{Run to cursor} --- Execute all statements up to the current cursor position. \item \textbf{Quit debugging} --- Immediately stop the debugging - session and stop the further code execution. + session and stop further code execution. \end{enumerate} The debugger offers some more (advanced) features but the -functionality offered by the basic tools is often enough to debug a program. - +functionality offered by the basic tools is often enough to debug a +program. diff --git a/designpattern/lecture/designpattern.tex b/designpattern/lecture/designpattern.tex index 6d08482..cebcf38 100644 --- a/designpattern/lecture/designpattern.tex +++ b/designpattern/lecture/designpattern.tex @@ -1,11 +1,11 @@ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\chapter{Design patterns} +\chapter{Design pattern} -Many code fragments are variations of some basic patterns. These -patterns are used in many different variations in many different +Many code fragments are variations of some basic pattern. These +pattern are used in many different variations in many different contexts. In this chapter we summarize a few of these \enterm[design -pattern]{design patterns}. +pattern]{design pattern}. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \section{Looping over vector elements}