Data structures?
-
Anyone see the need for articles covering data structures on Code Project? Quite frankly, STL is great, but it's promoting a whole new generation of "data structure unaware" programmers. Tell me what you think. "Assumptions are the mother of all screwups" - My esteemed colleague, Bug Druid.
-
Anyone see the need for articles covering data structures on Code Project? Quite frankly, STL is great, but it's promoting a whole new generation of "data structure unaware" programmers. Tell me what you think. "Assumptions are the mother of all screwups" - My esteemed colleague, Bug Druid.
I don't think the STL is responsible for newbies not understanding data structures. There's always a group of "programmers" that really don't have a clue. I wouldn't blame their cluelessness on STL.
-
Anyone see the need for articles covering data structures on Code Project? Quite frankly, STL is great, but it's promoting a whole new generation of "data structure unaware" programmers. Tell me what you think. "Assumptions are the mother of all screwups" - My esteemed colleague, Bug Druid.
"data structure unaware" programmers. If you want to write an article that details the the differences and advantages/disadvantages of vectors/lists/maps/etc the I think that's a good idea. A strong understanding o the nature of different data structures (whether it's STL, MFC or some other structure) is a good thing. If you want to write an article about "how to implement data structures", then I think this is of far less value - it's not that it's 'bad', it's just that there are so many good libraries (like STL) around now that it's unlikely that you'll need to roll your own, so learning 'how' is just an exercise in programming. That doesn't make it bad, but I can think of many other ways of practicing design/programming skills. ----------------------- The sermon on the mount... Man 1 : Hear that? Blessed are the greek. Man 2 : The greek? Man 1 : Well apparently, he's going to inherit the earth. Man 2 : Did anyone catch his name?
-
Anyone see the need for articles covering data structures on Code Project? Quite frankly, STL is great, but it's promoting a whole new generation of "data structure unaware" programmers. Tell me what you think. "Assumptions are the mother of all screwups" - My esteemed colleague, Bug Druid.
No more data unaware than the developers that seem to think that everything needs to be either 1) in an array, or 2) in an XML DOM (as the data structure). STL was shunned, and God forbid you build a generic templated linked list class and use it where it's more appropriate than an array. (If you can't tell, I'm venting. Grrr...) --CoolDev :cool:
-
"data structure unaware" programmers. If you want to write an article that details the the differences and advantages/disadvantages of vectors/lists/maps/etc the I think that's a good idea. A strong understanding o the nature of different data structures (whether it's STL, MFC or some other structure) is a good thing. If you want to write an article about "how to implement data structures", then I think this is of far less value - it's not that it's 'bad', it's just that there are so many good libraries (like STL) around now that it's unlikely that you'll need to roll your own, so learning 'how' is just an exercise in programming. That doesn't make it bad, but I can think of many other ways of practicing design/programming skills. ----------------------- The sermon on the mount... Man 1 : Hear that? Blessed are the greek. Man 2 : The greek? Man 1 : Well apparently, he's going to inherit the earth. Man 2 : Did anyone catch his name?
Thanks for the thoughts! But I beg to differ on your point regarding it's of 'far' less value. If so, why does every computer science course place a major emphasis on data structures? Data structures teach much more than routine programming-one also needs to analyze the solutions in terms of efficiency, etc. This will undoubtedly bolster analytical skills in your everyday programming-even when you use STL. Besides, there will come a time when the STL may *not* cut it for a certain type of structure-hash tables come to mind. Here's a thought: using STL over your own data structures might be good and is akin to class abstraction (you 'insulate' yourself). Unfortunately, excessive abstraction can be a bad thing too-you know it works-but not *why*. My 2 cents. :suss: "Assumptions are the mother of all screwups"
-
No more data unaware than the developers that seem to think that everything needs to be either 1) in an array, or 2) in an XML DOM (as the data structure). STL was shunned, and God forbid you build a generic templated linked list class and use it where it's more appropriate than an array. (If you can't tell, I'm venting. Grrr...) --CoolDev :cool:
Ah...nicely put. I empathize with you...come to think of it, STL code is so gobble-de-gook (for obvious 'copyright' reasons). Ugh. Thank God MFC wasn't mangled. :suss: "Assumptions are the mother of all screwups" - My esteemed colleague, Bug Druid.
-
Thanks for the thoughts! But I beg to differ on your point regarding it's of 'far' less value. If so, why does every computer science course place a major emphasis on data structures? Data structures teach much more than routine programming-one also needs to analyze the solutions in terms of efficiency, etc. This will undoubtedly bolster analytical skills in your everyday programming-even when you use STL. Besides, there will come a time when the STL may *not* cut it for a certain type of structure-hash tables come to mind. Here's a thought: using STL over your own data structures might be good and is akin to class abstraction (you 'insulate' yourself). Unfortunately, excessive abstraction can be a bad thing too-you know it works-but not *why*. My 2 cents. :suss: "Assumptions are the mother of all screwups"
If so, why does every computer science course place a major emphasis on data structures? These are the same courses that (generally) used to emphasize Pascal, and have now moved to Java, right? The answer is that (a) until the advent of the STL there was NO widespread container (data structures) implementation available for C++, so it was necessary to teach programmers how to write them; (b) they DO provide a clear and clean initial lesson in design and programming; and (c) universities are ALWAYS playing catch up - the lecturer teaches what he knows, and when did he learn it? Five or ten years ago! This is just the nature of the beast. To sum up, I believe that Unis teach data structures because they have not yet realised it is no longer a cornerstone of the skillset - old habits die hard. Data structures teach much more than routine programming I agree - my point is that there are other topics that teach these lessons just as well, or better, and are more practical (that is, of real world use). For instance, designing a set of custom manipulators for iostream use that can read/write XML - detailed, involves lots of decisions and tradeoffs in implementation, and does NOT replicate an existing part of the standard C++ library. Or building a set of 'smart pointer' classes that trade off the various strengths and weaknesses of the smart pointer concepts - this can then be used as a substitute for the default 'auto_ptr'. Besides, there will come a time when the STL may *not* cut it for a certain type of structure-hash tables come to mind Yes, hash tables are an option for an article. STL does not have a standard hash table, although most STL implementains offer at least one 'non-standard' hash table. My 'far less useful' would be in relation to any artile that was describing the gory details of how to build vectors, lists, maps, sets, trees, etc. ----------------------- The sermon on the mount... Man 1 : Hear that? Blessed are the greek. Man 2 : The greek? Man 1 : Well apparently, he's going to inherit the earth. Man 2 : Did anyone catch his name?
-
Anyone see the need for articles covering data structures on Code Project? Quite frankly, STL is great, but it's promoting a whole new generation of "data structure unaware" programmers. Tell me what you think. "Assumptions are the mother of all screwups" - My esteemed colleague, Bug Druid.
when they taught us data structures in college I said, "yuck, why would anyone want to make circular queues and n-trees or whatever" now that I have realized why, its too late.... wish i had paid attention then would have made things a lot easier whats funny is lots of advanced level MFC programmers would probably have a lot of trouble of they were asked to implement a doubly linked list in plain c++ Nish
-
when they taught us data structures in college I said, "yuck, why would anyone want to make circular queues and n-trees or whatever" now that I have realized why, its too late.... wish i had paid attention then would have made things a lot easier whats funny is lots of advanced level MFC programmers would probably have a lot of trouble of they were asked to implement a doubly linked list in plain c++ Nish
whats funny is lots of advanced level MFC programmers would probably have a lot of trouble of they were asked to implement a doubly linked list in plain c++ IMHO only if they hadn't figured out pointers yet (and yes, I've worked with C++ programmers who haven't. It was painful). More advanced data structures require some theory, so if you haven't studied them before, you have some learning to do - but I don't think it's difficult (no more abstract than visualising class hierarchies anyway). I remember writing doubly linked list and search routines in JRT Pascal (pre-OOP) on a Z-80 in about 1985, and I'm glad those days are long past. :) Andy Metcalfe - Sonardyne International Ltd
(andy.metcalfe@lineone.net)
http://www.resorg.co.uk"I'm just another 'S' bend in the internet. A ton of stuff goes through my system, and some of the hairer, stickier and lumpier stuff sticks." - Chris Maunder (I just couldn't let that one past ;))
-
Ah...nicely put. I empathize with you...come to think of it, STL code is so gobble-de-gook (for obvious 'copyright' reasons). Ugh. Thank God MFC wasn't mangled. :suss: "Assumptions are the mother of all screwups" - My esteemed colleague, Bug Druid.
Ah...nicely put. I empathize with you...come to think of it, STL code is so gobble-de-gook (for obvious 'copyright' reasons). Ugh. Thank God MFC wasn't mangled. Every time I look at the STL code I feel like punching someone. Whilst I understand the reasons, the authors aren't doing themselves any favours - it just makes STL harder to use. The crap documentation doesn't help either - but at least that's supposed to be better in VS.NET. :) Come to think about it, can anybody confirm that it is? Andy Metcalfe - Sonardyne International Ltd
(andy.metcalfe@lineone.net)
http://www.resorg.co.uk"I'm just another 'S' bend in the internet. A ton of stuff goes through my system, and some of the hairer, stickier and lumpier stuff sticks." - Chris Maunder (I just couldn't let that one past ;))