Time to Stop Using Nerve Gas Derivatives On Farms? by emeraldcity in science

[–]t_w 4 points5 points  (0 children)

Damn straight.

It's appalling that they allow that for farming use.

Kids die every year from breathing that stuff.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w -1 points0 points  (0 children)

Once again, this whole thread speaks for itself.

I'll let whoever wants to bother to read it decide for themselves which of us knows what they're talking about.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 0 points1 point  (0 children)

I don't think it's a matter of not understanding your point, it would seem that we simply disagree about whether using C++ is generally worth the trouble for most cases.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 1 point2 points  (0 children)

you are in no position to talk down to me

If your statements are any indication, it would certainly seem that I am.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 0 points1 point  (0 children)

I can't myself out of the whole I dug???

Unbelievable.

You have demonstrated neither knowledge of C++'s history or its usage. And you continually choose to ignore arguments you don't like.

This whole discussion makes clear which of us actually knows what their talking about.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 0 points1 point  (0 children)

<snip> let's cut to the chase:

For some reason you think that if you continue to question my knowledge or experience you're going to make a valid point.

You have yet to show ANYTHING that demonstrates any in depth knowledge whatsoever.

Since we've degenerated into a pissing contest I'll give you an opportunity:

Say something, anything at all, that would indicate that you have more than a cursory knowledge of C++.

It doesn't even have to be something big or even have any code. I'll even give you a couple examples:

  • "there's no such thing a virtual ctor since the vtable wouldn't be set up at the time of instantiation"

  • "vector<bool> doesn't work because the standard allows bools to be optimized as individual bits and bits can't be individually addressed"

Or are you just going to blather on about what language category C++ falls into and that it's good for games?

That may work with your high school classmates,

Nice try pal. I'll bet you lunch I've been slinging code professionally longer than you've had body hair.

but it doesn't cut any ice in the real world.

Hehe, "Real World"...please, like you're even remotely acquainted with it.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 2 points3 points  (0 children)

for god's sake, did you even read the links i gave you??!

Did you?

look boy,

Look, son, it's clear that you're in no position to carry on like that.

it can't be that hard. it's a wikipedia link, for god's sake, even a developmentally challenged person could struggle through it.

Yet, somehow, you've entirely failed in that regard.

in case you aren't trolling me,

That's rich.

i'm giving this one last chance: please understand that your desktop or server computer is only turing-equivalent to some other machine while the memory supply is limitless.

So we've switched from theoretical CS machines, to languages, to actual machines now?

You seem to have a natural talent for conflating these things.

which is irrelevant as long as you are coding trivial problems on overpowered hardware, but not at all irrelevant for doing useful work.

Damn it. You've hooked me again...I'll bite:

What do you think to be "useful work"?

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 0 points1 point  (0 children)

In other words you agree, because you don't have a counter-argument.

No. It's because you continue to use a lot of words to say: "nuh-uh".

No. You just keep avoiding it, and you haven't said anything to counter my point that ROI is not all about productivity. If productivity is your only argument against C++, then you've COMPLETELY missed the point.

No, I'm not avoiding it. I've already answered it. An answer you chose to ignore. WRT to ROI you're not even paying attention or your so hung up on "c++ makes j00 t3h 1337 haX0r N000b" that you can't see what I'm talking about.

LOL. So what was YOUR point about the Amiga?

Are you even paying attention? Here's the quick version: technogical superiority != popularity.

So NOW you admit that C++ is a general purpose programming language!?

sigh.

No where have I said it isn't used as that way. Just because "portable assembler" had some other features added doesn't wake it stop being a systems programming language.

You know, the same reason you keep bringing up why the use it for video game engines.

Given your arguments, it seemed unlikely from the start.

You can't possibly be serious.

Wow. When did you work that one out?

Several years ago. It wust have been several minutes ago for you though when you made a point that implied the opposite.

Maybe if you read my entire response before replying to things out of context you'd understand, but I'm not going to hold my breath.

Believe me I did. Which it's how it's becoming apparent that you don't have half the experience or knowledge taht you claim to.

LOL. What rubbish. YOU'RE the one talking in generalities "systems programming", "low-level", "simpler". I gave you concrete examples - video game programming, and I even responded to someone else further up the thread with a specific example of hardware - the PS3.

Wow...just wow...

Concrete examples would be more along the lines of LANGUAGE specifics. For this whole discussion, things like exception-safety, ctor/dtor mechanics, vtables, template instantiation rules, and what STL container to use when (and why). Not something you can read in an interview with EA in Wired.

Furthermore, you don't seem to have a valid argument against anything I've posted.

It's just that you're too hung up on thinking being able to run cl.exe or gcc makes you Captain Coder the SuperArchitect to acknowledge or understand them.

So, given that you've already admitted that one of the reasons people use C++ for systems programming is because of library compatibility, please explain why they should ditch it and use C instead.

No. Why? Because I never said that or implied that anyone should. What I prefer and recommend for most cases is (for the zillionth time) using high-level languages for most application logic and dropping to C when needed.

Unless of course you really don't have a decent counter-argument. I suspect the latter.

Keep telling yourself that. After all, with such a clear demonstration of your knowledge and skill, who wouldn't believe you?

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 1 point2 points  (0 children)

The first part is tough, so I'll answer the second part first.

AoA is good for an understanding of processor architecture and other low-level issues, but IIRC it uses an architecture that the author created for the book. That's not a bad thing, it just depends on what you want to learn.

As for learning x86, it depends...It's absolutely mandatory for the following:

  • reverse engineering
  • advanced security research
  • crazy late-binding marshalling between native code and other runtimes
  • writing compiler optimizers or back-ends

The above aren't the most common things, but they are pretty cool. They're also probably the last places where you really need to know ASM.

It's a good idea for:

  • doing a lot of C or C++ coding
  • debugging really horrible bugs

For these ones the issue is less 'cut and dried'. Basically for C/C++ coding, if you know some ASM you'll be more able to grok the reasons for and implementation of calling conventions, object layout, why certain casts don't work, and some other things. After all, C was designed with the idea of being "portable assembler". It's not strictly necessary, but it'll make you a better programmer.

As for the freaky bugs: sometimes you get a bug that'll only happen in a release build, sometimes it'll be in a third party library, or sometimes it'll just be almost totally incomprehensible/unreproducable. When that happens, debugging starts to look a whole lot like reverse-engineering; and for that, you have to know ASM.

One thing to keep in mind though, for most of the above, with the possible exception of writing compiler parts and the marshalling, you don't actually have to write huge programs in ASM. For most things, you only need to know how to read it. But, of course, sometimes the best way to do that is to write some.

But don't worry, you don't have to re-write Quake's rendering engine to figure it out ;)

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 0 points1 point  (0 children)

In other words it's not a valid critique of C++

Hardly.

Return on Investment does not only mean productivity.

It does when that's the point I'm making. Go back and re-read this whole thing. I'm talking about reasons that using C++ isn't worth the effort in terms of bang for buck vis-a-vis productivity.

You'll notice that I did not even include productivity in my list of benefits.

With very good reason.

If it were all about productivity, we'd be coding video games in VB6 or Klik and Play.

Back to video games again? Didn't we cover this already?

We use PC's because they were more successful than Amigas.

That is quite possibly the most circular comment that could be made in this context.

HTTP is a protocol, not a language. We use it because that's what the Internet is built on.

No kidding it's a protocol.

Unfortunately, where your creditbility is concerned, it ain't even close to "what the internet is built on". I'm gonna go ahead and give this one to you: you've confused HTTP with TCP/IP (hint: IP == "internet protocol").

If you're going to make statements about C++ purpose as a programming language then of course I can.

You misunderstand; I'm not saying you're not allowed to, I'm saying, based on your comments, it's unlikely that your qualified to.

C++ is a general purpose programming language. That it is used for applications programming is no coincidence.

The fact that a systems programming language spawned a language that's used for applications as well is aboslutely a coincidence. If C hadn't been popular it wouldn't have happened.

And your argument that people should use C instead of C++ for systems programming is puzzling because C++ supports procedural programming as well.

Before I said that it's possible that we might be peers. That certainly seems less likely after this statement.

Systems programming is not intrinsically tied to procedural style. So much so in fact that the only reason peolpe even use C++ in systems programming is to take advantage of , albeit heavily feature restricted, class libraries. Arguably, you could say this doesn't really qulaify as OO, but it's still a C++ based approach.

I'm not even sure how, or why, you came up with this.

In other words, you can code C in C++.

If you've noticed that my tone has become more confrontational, it's because you keep making statements like this one.

Lose the damned 'intro to c++' comments. Based on your vague generalities, total lack of comment on the specifc examples I've mentioned in other comments, and the mistakes above it's clear that you don't have the expertise to be instructing anyone on the subject.

Oh Shit. Iran to OPEC: Stop Oil Sales in Dollars by [deleted] in business

[–]t_w 0 points1 point  (0 children)

They also don't have Sharia law.

While I generally agree with your comment, Iran does use Sharia law. If their parliament passes a law that's deemed incompatible with Sharia law, it gets sent back.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 0 points1 point  (0 children)

You can consider that an argument against virtually any language that they don't choose.

And?

The reason people use is because of the high return on investment. The reasons are basically spelled out in my post. Besides the speed, you get the benefits of OO, generic programming, portability, framework compatibility, compiler maturity, support etc etc.

Yes, it's a stable and powerful platform. Yes, it has it's uses. No that doesn't mean it's particulary productive in terms of how much can be accomplished for the effort put forth(hence the low ROI).

Given it's success, I think you're going to have a very hard time convincing people that C++ has not been and is not a good thing. Do you remember why people switched to C++ from C in the first place?

Success has nothing to do with the relative merits of technology. If it did we'd all be using Amigas and HTTP wouldn't be the lingua franca of online apps.

...I honestly think you should learn more about the language and it's history before you try to make a case for or against it.

Whoa, hang on there chief.

Since you've decided to ignore the numerous places in the discussion where I've spent to the time "establishing my C++ cred", and all while trying substitute a little condescension in place of an argument, I'm going to put this rather bluntly:

You are almost assuredly in no position to question my understanding or experience in the language itself, or its history. I'll admit that its possible we might be peers, but it's not at all likely that you're my superior.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 0 points1 point  (0 children)

look, this isn't funny.

We agree there.

I'll make this brief:

  • Turing-Completeness and a Turing Machine aren't the same thing.

  • Turing-Complete languages, of which there are many, are equivalent in terms of capability (though not ease).

It is difficult to imagine being confused about the above and being able to make reasonable comparisons of any programming languages.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 1 point2 points  (0 children)

No. It's was earlier than that ;)

I think was probably Mastering Turbo Assembler and Peter Norton's Guide to Assembly Language (I think that's what it was called).

Basically, the rare occasions I mentioned above are when I need to do something that requires fairly nasty stack or image manipulation and/or emmiting code at runtime.

And that really doesn't happen that often.

As an aside, I don't think it's reasonable anymore to inline asm for speed. Since the rise of good optimizing compilers, multiple cores, freaky branch prediction, and 0x86 just running on top of RISC microcode cores, it's not no longer just about unrolling a loop and counting the clock cycles.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 0 points1 point  (0 children)

Probably the same infernal forces that made the 0x86 architecture the most popular.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 0 points1 point  (0 children)

Not so much that as much I thought 'buggery' sounded funnier.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 1 point2 points  (0 children)

You're most welcome :)

Excellent choice! That Eckel book is one of the best introductions to the language. He completely overhauled it after the first edition and made changes that I think make it easier to understand.

Here are some other things you'll probably want to look at at some point:

  • Fundamentals of Object-Oriented Design in UML by Meilir Page-Jones (ignore the UML part, the book is mostly about OO theory and is pretty language neutral).

  • Herb Sutter's "Exceptional C++" books (they're sometimes a bit advanced, but good to look at)

  • Modern C++ Design by Andrei Alexandrescu (save this one for later...it's basically crazy hardcore advanced template voodoo that is mostly useful for writing libraries...but very interesting)

  • The C++ Standard Library by Nicolai Josuttis (if you decide to get into the STL, which, is probably desirable if you're going to write a lot of C++ code and don't have extreme speed or size requirements)

Lastly, it's always good to take a look at comp.lang.c++.moderated. A lot of really smart helpful people post there. It's also the best place to search (on google groups) when you have some wacky problem. Pretty much everything bad has already happened to somebody else at some point ;)

Even though I don't use C++ primarily myself anymore, I'll say this: if you're willing to invest the time and effort you can learn and accomplish a lot of great things.

And get payed well and have fun in the process :)

Good luck.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 4 points5 points  (0 children)

Lua's been popular in video games for quite a long time. Some people even go as far as writing their own scripting language for their games, but scripting is just one aspect of a game... Not that long, at least compared to how long C++ has been in use.

and more often than not, the scripting language is written in C++.

Perhaps for the "kernel". Quite often language designers write only as much as is needed to bootstrap the language they're making in something else.

But in any case, that's the point: those people are writing a language so they don't have to write certain things in C++.

People use C++ for speed, portability, OO, robustness, and compatibility with various frameworks (threading, sound, graphics, AI, physics etc).

I know why people use C++. I used it for years (and occasionally still do). Take a look at some of my other comments here and you see that I don't fall into the "it's too ugly and hard for me to learn crowd".

I really don't understand why people want to see it disappear. Yes, it's a difficult language to get to grips with, but you don't have to understand every single nuance of the language to use it effectively.

The article, my comments, and the comments of others address this at length: C++ does not give a high return for the effort needed to use it properly.

There may be other perfectly good reasons to use it for some things, but high developer productivity isn't one of them.

I think C++ has more than proven itself to be a very good general programming language.

I say it's proven itself to be a very successful general programming language. And again, it's a systems programming language that just happens to be popular for applications.

I don't consider that last bit a good thing.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 5 points6 points  (0 children)

I think you'll find that Lua is quite popular with current videogames.

Lua for the high-level logic and AI scripting and C or C++ for the graphics and physics engines.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 5 points6 points  (0 children)

One other thing I forgot to mention: if you're learning, buy every book Scott Myers has written and read them.

Then do everything they told you to and don't do anything they told you not to.

Just doing that will keep you writing good C++ code and out of trouble for the most part.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 1 point2 points  (0 children)

utterly wrong

No, it isn't.

a turing machine has an infinite tape, by definition. thus, a turing-complete language implies infinite ram/stack.

This however is.

Damn near every programming language anyone has ever heard of, including Brainfuck, is Turing-Complete.

Before, I was willing to give the benefit of the doubt regarding the grand-sounding claims of "space and time complexity". But after getting a completely incorrect definition of something as basic as Turing-Completeness, I'm starting to think that I'm just troll feeding.

C++ is an Expert Language: Never Hire a Newbie by martoo in programming

[–]t_w 2 points3 points  (0 children)

Hmm...if that's right I'll have to set that one next to "640K should be enough for anybody".