tags:

views:

1992

answers:

5

I'm looking for interesting exercises to code that would be suitable for an intermediate level c++ programmer. I know that the 'term' intermediate covers a lot of ground and varies from person to person but just post what you think would fall into the category.

Thank you.

+2  A: 

I would get deeply familiar with templates and tools from the STL. Understanding C++ style on this side of things can be very helpful. Begin working with complex data structures in C++ and take advantage of relevant features such as iterators.

C++ is used heavily for object-oriented design. As such, it's worth learning the C++ side of things rather than simple C usage compiled with a C++ compiler. Begin working with inheritance - virtual inheritance, multiple inheritance, and so on.

I would definitely look at data structures and their associated in algorithms.

Tony k
I was looking more for ideas that combined what you posted into exercises :) Thanks anyway!
Jamin Huntley
+5  A: 

I think these will be interesting to solve:Questions

Naveen
Wow, amazing resource, thanks.
Jamin Huntley
Voted up for same sentiment^^.
Unknown
+1  A: 

The Definitive C++ Book Guide and List will help you pick some books. Look up the intermediate section. Choose one and read up the problem description and try to solve it yourself. Next compare it with the author's solution.

Edit: I am reading up on Greg Reese's C++ Standard Library Practical Tips which also has a problem description followed by solution approach. The material is good (though may not be exceptional for some) and makes a decent read.

dirkgently
Is there a specific book out of those listed that presents a problem then solution format? Or are you just talking in general?
Jamin Huntley
Sutter's and Meyer's books take up individual problems/puzzles and address them. Alexandrescu and Josuttis mostly take up generic topics and is like any other book. But they do discuss problems. No idea about Lakos though.
dirkgently
Sutter's works include material from the GOTW series and more.
dirkgently
+2  A: 

It depends on which kind of exercises you want; you can focus on general programming oriented exercises, or more language-specific exercises. For the former, you can try implementing and optimizing algorithms to do practical specific tasks (rather than implement the basic data structures). http://www.projecteuler.net has many exercises which are based on implementing mathematical algorithms efficiently, for example.

For language exercises, pretty much any C++ book will contain many. Bjarne Stroustrup's "The C++ Programming Language" is probably the quintessential one.

Volte
A: 

Some interesting task, which could be asked at interview: http://geeksforgeeks.org/?cat=14

LonliLokli