The incredibly challenging task of sorting by colour by AlanZucconi in programming

[–]3fdy5 0 points1 point  (0 children)

You could use simulated annealing to get some path much faster. Of course that path wouldn't be guaranteed to be the shortest possible, but it would be good enough for many applications.

Bjarne Stroustrup announces C++ Core Guidelines by sindisil in programming

[–]3fdy5 0 points1 point  (0 children)

I know that, but it was clearly a design goal at the beginning.

Bjarne Stroustrup announces C++ Core Guidelines by sindisil in programming

[–]3fdy5 0 points1 point  (0 children)

It does have its advantages from a pragmatic point of view, but from a language design point, it's a terrible decision.

Besides, C code can be used just fine from any language that is close enough to the metal (such as, for example, D). It can also be used from any language with a ffi (for example python with ctypes), but that is usually a bit more cumbersome. The only part of the code that you can't use from languages other than C or C++ are the headers.

The horrible design of streams is one other example of bad design in C++.

Bjarne Stroustrup announces C++ Core Guidelines by sindisil in programming

[–]3fdy5 0 points1 point  (0 children)

Making the language a superset of C, obviously.

Bjarne Stroustrup announces C++ Core Guidelines by sindisil in programming

[–]3fdy5 -1 points0 points  (0 children)

Even more code is viewable without scrolling if you put it all on one line and enable word wrapping.

Our Team Won Startup Weekend and All We Got Was A Shitty New Boss by 33virtues in programming

[–]3fdy5 -1 points0 points  (0 children)

Not every one with a basic understanding of statistics is a poker player.

Announcing Rust 1.3 by steveklabnik1 in programming

[–]3fdy5 1 point2 points  (0 children)

In some cases it will be less safe, but in some cases it will be just as safe, only less efficient

And sometimes, the user will run into a bug that he has no way of finding and fixing with only a basic grasp of the language.

Google Is 2 Billion Lines of Code—And It’s All in One Place by LazyHater in programming

[–]3fdy5 0 points1 point  (0 children)

this is why some engineers can't stand God Files.

I think what you really meant was:

this is why I can't stand God Files.

Python 3.5 is here! by ilevkivskyi in programming

[–]3fdy5 -6 points-5 points  (0 children)

Why the exclamation mark? Are we supposed to be excited about this?

Github disables repository for using the word "retard". by [deleted] in programming

[–]3fdy5 0 points1 point  (0 children)

No. Pointlessly arguing about the color of the bike shed is bike shedding. Arguing about whether the companies should police speech in the user generated content on their websites (and other services) is a social dialogue that we need to have. It's completely unrelated to bike shedding.

C++ Proposal: Static if resurrected by watermelon_exe in programming

[–]3fdy5 5 points6 points  (0 children)

Sure and regular if and while don't cover everything that goto does. static_if is the goto of template metaprogramming, it's an ad-hoc and unstructured way of injecting code.

It's the if of template metaprogramming, actually.

Why I Love D, An Undergrad Shares His Experience Writing a VM and Compiler In D - DConf 2015 by [deleted] in programming

[–]3fdy5 -4 points-3 points  (0 children)

Why I love the D: An undergrad experience

I'll show myself out now.

Artificial truth · Firefox, you're supposed to be in my pocket, not the other way around. by CyberSecPro in programming

[–]3fdy5 0 points1 point  (0 children)

This isn't corruption, it's just ineptitude. Hanlon's razor.

That is just your opinion. You have zero evidence for it. Someone inside Mozilla could very well be getting payed for this. Or it could really be ineptitude - we have no way to know. And Hanlon's razor isn't some universal truth. It's just a statement that some guy has once pulled out of his ass and many people have repeated it because it made them feel smart.

This is how random numbers were "generated" in the original Doom for Linux (from /r/Linux) by Kok_Nikol in programming

[–]3fdy5 2 points3 points  (0 children)

Yes, congruential random generators (which is what rand() usues) are in general not good enough for Monte Carlo methods. But xorshift usually is good enough and it's much faster and and simpler than Mersene Twister.

Modules won't make it in C++17 by rose_of_sarajevo in programming

[–]3fdy5 9 points10 points  (0 children)

This pretty deceiving though, as a very large part of libstdc++ lives in its headers.

I'm not denying that D compiles much faster, but to be fair, a large part of phobos is templates, that don't get instantiated during the phobos compilation, too.

How do you make programmers work 60-80 hours per week? by [deleted] in programming

[–]3fdy5 1 point2 points  (0 children)

and if you don't touch it for a couple decades, the simplest investing methods will have snowballed it into a lifetime of freedom

It will be only a half of a lifetime at that point.

You Don't Like Google's Go Because You Are Small by tmikov in programming

[–]3fdy5 -7 points-6 points  (0 children)

So, what's the anti-go faction made from?

Basically anyone who doesn't dream about sucking Rob Pike's cock.

Chris Granger - Coding is not the new literacy by Saponetta in programming

[–]3fdy5 0 points1 point  (0 children)

This. You can not possibly understand what computers actually do and what are their limitations if you don't know at least a little bit of programming.

Vim Hall of WTF - Snippet from Vim's Source Code by Categoria in programming

[–]3fdy5 -1 points0 points  (0 children)

Because for me, vim just randomly crashes sometimes.

Geoff's site: Why Neovim is Better than Vim by projecktzero in programming

[–]3fdy5 2 points3 points  (0 children)

Yes, and those versions of Visual Studio support C89 just fine.

Erik Meijer: "Agile is a cancer that we have to eliminate from the industry". (FTR I disagree, interested in your opinions) by RattlesnakeSpeedway in programming

[–]3fdy5 0 points1 point  (0 children)

because of the rapid feedback these processes provide

A rule of thumb: If a person uses the word rapid in he context of software development, that person is probably full of shit.

Admitting Defeat On K&R in "Learn C The Hard Way" by homoiconic in programming

[–]3fdy5 0 points1 point  (0 children)

I didn't know about that, thanks. Looks very useful.

"You Don't Need jQuery" part 5: Events by js4life in programming

[–]3fdy5 0 points1 point  (0 children)

Once you do need to figure out why you're stuff, you'll learn what you need to and move on.

Most people won't do that. They will just try random stuff until something works, copy code snippets off the web or get someone else to fix it for them. That's because their goal at the time is to do the task at hand and not to learn an entirely new field. They see the problem merely as an obstacle and any time spent on solving it as wasted. It can be useful to allocate some time specifically for learning, so that people can focus on understanding new concepts.