Programming Puzzles/Homework etc

Started by
5 comments, last by szecs 13 years, 9 months ago
Hi,

I am trying to build up a better logical approach to solving problems in C++. Hence i am looking for some questions which would qualify for "Homework" or "Interview" Questions flagship. Examples of such questions include.

- Remove an element in Array/Vector (delete it)
- Sort an array.
- Remove duplicates from array.
- Reverse a string/recursively.
- Traverse a tree/list.
- Find highest sum in the sequence of array elements {1,2,-1,-5,4,6} i.e range indexes.

I.e in short problems which are easy to solve , yet have optimized solutions.

If some one has a book which presents such brainteasers , please let me know. All links are welcome as well.. I lack Googling skills so more or less i end up with the usual "Why copy constructor"

Cheers!
Advertisement
http://projecteuler.net/
http://www.topcoder.com/tc
http://mindcipher.net/
You'll probably want to go a bit beyond the above if you want questions that would qualify for "Homework/Interview". The examples you gave would be in-class excersizes mostly, they are quite trivial.

You need problems with a bit more "meat" to build up your technique. Have you tried Project Euler?
Project Euler looks fantastic ; I'll be honest, they do look a little out of my league.

As you said I guess i need to build from bottom up... and look at a little more simpler problems... I am willing to invest a deal of time to get this right.

I'll start cracking at project euler.. but would still prefer some class-work exercises :)


Cheers!

PS : I <3 GDNET and the inhabitants here. Honest!
Um...
May I suggest to make a game (without tutorials)? You'll face logical problems for sure
Hi szecs, thanks for your suggestion. I have already done so.I have tried my hand & succeeded at tetris ;)
Quote:Original post by _korg
Hi szecs, thanks for your suggestion. I have already done so.I have tried my hand & succeeded at tetris ;)


Then go on to the next one. Or your dream project (if you have one)

This topic is closed to new replies.

Advertisement