background preloader

C++

Facebook Twitter

Patterns: Non-Software Examples of Software Design Patterns - AGCS. Non-Software Examples of Software Design PatternsbyMichael Duell Abstract Software design patterns have roots in the architectural patterns of Christopher Alexander, and in the object movement.

Patterns: Non-Software Examples of Software Design Patterns - AGCS

According to Alexander, patterns repeat themselves, since they are a generic solution to a given system of forces. The object movement looks to the real world for insights into modeling software relationships. With these dual roots, it seems reasonable that software design patterns should be repeated in real world objects. 1. Within the software industry, a growing community of patterns proponents exists. Since objects were the predominate world view at the time that patterns were embraced by the software world, patterns also have roots in the object movement [9].

Computer Science 10 - Advanced C++ Programming. Seminar: Lecturer Participants.

Computer Science 10 - Advanced C++ Programming

C / C++ Programming. Sparse Matrix Implementation. Mar 4, 2009 at 3:21am Mar 4, 2009 at 2:21am UTC The following is my implementation of a sparse matrix class.

Sparse Matrix Implementation

Feel free to comment on my bad coding style as well as use the code. The input file is the bcsstk14 matrix from Space savings is huge for this matrix. There is a multiplication timer in the test file, it comes out with .005 seconds whereas dense multiplication takes about 7 seconds (Linux P4 2.3GHz) for this matrix. Matrix class header test program. More C++ Idioms. Preface[edit] More Information[edit]

More C++ Idioms

Learn C++ Metaprogramming Concepts - Home. Templates Refresher The first section provides an overview of different forms of templates in C++, knowing which is vital to understanding the methods of metaprogramming Building Blocks Here you will see some of basic techniques used in compile-time algorithms DrScheme.

Learn C++ Metaprogramming Concepts - Home

AW * Main/Savitch * Supplements: Data Structures ... Using C++ Writing correct code, part 2: bound functions (binary search part 4b) Following on from yesterday’s article on invariants, this time we’ll talk about a second tool in the kit for thinking about code.

Writing correct code, part 2: bound functions (binary search part 4b)

This one will be much shorter, because the Concept Of The Day is so simple. It gets talked about even less than invariants, but let’s change that! (Oh, and today is vegetarian-friendly Cheese Day at The Reinvigorated Programmer, though it still may not be much use to the vegans among you.) What is a bound function? You’ll remember that last time I said: “if your invariant properly expresses the intent of the algorithm, and if your code properly maintains the invariant, then that is enough for you to be confident that the code, if it terminates, yields the correct answer.”

The bound function of a loop is defined as an upper bound on the number of iterations still to perform. Writing correct code, part 1: invariants (binary search part 4a) I’m struggling with my article numbering now :-) Regular readers will have noticed that I am running a whole bunch of series in parallel on this blog: one reviewing programming books, one on the issue of simplicity in programming, one reviewing Series 5 of Doctor Who, a related one on Russell T.

Writing correct code, part 1: invariants (binary search part 4a)

Davies’s contributions, and one on learning Lisp. To my huge surprise, what started out as a review of Jon Bentley’s book Programming Pearls [amazon.com, amazon.co.uk] has led through a sequence of digressions and become a series of its own on binary search. This is part 4 of that series: when I’ve finished part 4, I will — at last! — progress to the actual review. A few people have complained about the sushi pictures on this blog, so before I plough into the article proper, here is something completely different. Testing is not a substitute for thinking (binary search part 3)

The contributions to the original binary search thread continue to trickle in, and now stand at an astonishing tally of 679 comments, most of them containing code.

Testing is not a substitute for thinking (binary search part 3)

Thanks once more to all of you who’ve attempted this challenge, and to everyone who’s commented. In one of the more interesting comments, Darius Bacon tested a sample of 20 of the Python submissions, and found that exactly 10% of them both passed the functional test and appeared to run in O(log n) time — which of course is exactly in line with Jon Bentley’s original statistic, that 10% of the professional programmers he’d examined were able to write correct binary search code (albeit under rather different conditions). AW * Main/Savitch * Supplements: Data Structures ... Using C++ Design Patterns. CodeProject.com. A simple introduction to static and dynamic libraries with Microsoft Visual C++.

C++, Visual-Studio, Dev, Virtualization, virtual-machine This article gives a brief overview of C style bitwise operators A simple introduction to static and dynamic libraries with GCC. An ideal source package for introducing students to the basics of Win32 programming Adapted WinMine Source for Teaching Win32 API Programming An article showing the use of pointers in C and C++ It's really weird that the C math library (math.h) doesn't support the round function. Dynamic loading. History[edit] Dynamic loading was a common technique for IBM/360 Operating systems (1960s to, the - still extant - Z/Architecture), particularly for I/O subroutines, and for COBOL and PL/1 runtime libraries.

Dynamic loading

As far as the application programmer is concerned, the loading is largely transparent, since it is mostly handled by the operating system (or its I/O subsystem). The main advantages are: Shared libraries were added to Unix in the 1980s, but initially without the ability to let a program load additional libraries after startup.[5] Uses[edit]