Thread: Sad Sigil news?
View Single Post
Old 10-04-2013, 07:36 AM   #141
DrChiper
Bookish
DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.
 
DrChiper's Avatar
 
Posts: 1,029
Karma: 2003162
Join Date: Jun 2011
Device: PC, t1, t2, t3, Clara BW, Clara HD, Libra 2, Libra Color, Nxtpaper 11
Quote:
Originally Posted by tompe View Post
But just describing the intention is not pseudo code. Pseudo code as I understand it is for describing what the actual implementation do and often describe before you implement.

The problem with this kind of pseudo code is that you have duplicated the information. If there is a mismatch you do not know if the pseudo code or the code is correct if both are working according to the interface specification.
Your statement is indeed what confuses most developers in their interpretation of what pseudo code is: it does not describe the actual implementation. The latter is up to the developer to decide: its his job, his area of expertise. Pseudo code is just an (high level) algorithm with the basic sequence of steps taken to solve a problem.

True, most "pseudo code" is (wrongly) written to even at bit-level, using real named parameters and hence, an 1-to-1 translation (cut/paste) can easily be made. In fact most "pseudo code" is just actual code because they get the abstraction wrong.


Spoiler:

Pseudo code example

WHILE calibre files are present DO:
Input calibre file
IF calibre file genuine and valid DO:
clean calibre file TOC
store result
update bookkeeping
update database
update GUI where necessary
ELSE
inform user about failure
log failure
END
END
Print totals in GUI


But this is basic programming skill and actually IMHO
DrChiper is offline   Reply With Quote