Sirs,

I have been reading code-guru posts for quite some time now over the last year, and am glad to finally be a member of the forum on a formal basis.

I am brushing up on some of my data structure knowledge, and have recently completed a class in data structures taught out of a book called "ADTs, Data Structures and Problem Solving with C++" by Larry Nyhoff. The book is replete with c++ code for creating linked lists, binary search trees, and other such data structures. The book is the second edition, and is copyrighted (c) 2005.

The problem I have been having for quite some time now is that an abnormal amount of the code in this book will not compile at all using the Visual Studio 2008 IDE. After hours and hours of searching, I often times find that the author forgot to list some #include statement, or some other feature.

I am not particularly cynical of Nyhoff. He is a professor of computer science at a university, and surely he's not so stupid as to totally forget things like this. Nevertheless, only about 1/10th of the code snippets in this book will actually compile. I am aware of a variety of changes that took place to the ANSI C++ standards in 2003, but the Nyhoff book is (c) 2005, and the code seems to be fairly up to date.

Although I am not a particularly strong C++ programmer (most of my bioinformatics and drug discovery algorithms are written in python -- certainly my strongest language), but it's not like I can't write a while-loop in the C++ language. As far as my experience level in C++, I can write a doubly-linked circular list -- so I don't think that all of this is simply due to inability to type correctly or inability to read and understand straightforward code.

I'm curious to know if anyone is aware of what the problem might be with Nyhoff's code in his fairly voluminous book of data structures. Why is it that the lion's share of his code will not even begin to compile, producing as many as 20 - 30 compile-time errors and other fatalities?

Finally, I realize that this problem may be difficult to solve without at least seeing some of the problematic code -- I'd be happy to email some of Nyhoff's non-compiling code to anyone who wants to look at it, I just didn't want to post 300 some-odd lines of code in the forum. I could also post some of the error messages at anyones requests (although they are a bit lengthy as well).

BrentC