[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y ] [Home]
4chanarchives logo
What is C++ used for in the industry besides GAEMS? It's
Images are sometimes not shown due to bandwidth/network limitations. Refreshing the page usually helps.

You are currently reading a thread in /g/ - Technology

Thread replies: 58
Thread images: 3
File: 1441513231065.jpg (391 KB, 1374x1425) Image search: [Google]
1441513231065.jpg
391 KB, 1374x1425
What is C++ used for in the industry besides GAEMS?

It's not used for web development or phone apps, so what's its purpose?
>>
>>53091001
>it's not used for web development
wrong
I know this is bait, but there's probably some of this that OP actually believes.
>>
File: qkkCZnT.jpg (581 KB, 2304x3456) Image search: [Google]
qkkCZnT.jpg
581 KB, 2304x3456
>>53091001
At least post full pictures.
>>
>>53091001
Your OS
>>
>>53091099
Who is she? Are there nudes?

Post them on /b/ and link us here.
>>
>>53091001
Most software that relies on high performance that isn't written in C.
>>
Here is a nice C++ joke:
http://stackoverflow.com/questions/10962290/find-position-of-element-in-c11-range-based-for-loop

It almost completely describes all problems with C++
>>
>>53091099
H I P S
I
P
S

How did she get that massive scar on her cheek and those huge rashes on her arms?
>>
developing software for embedded systems
>>
>>53091208
I don't see the problem.
>Question: How can I iterate over a collection and access both the value and index on each iteration?
>Answer: Use this handy utility class I wrote that does exactly that

In fact, the answer is both very helpful and a testament to C++'s flexibility.

(Not that I'm much of a C++ fan. But for someone trying to shit on it, you did a terrible job.)
>>
>>53091001
>It's not used for web development
Except for, you know, the http server, database, and interpreter for whatever scripting language the backend is running on. Not to mention the web browser that the page is rendered on, as well as the user's operating system.
>or phone apps
But it is used for the phone operating system, and the native libraries that the app uses to play videos, decode image files, or interact with any hardware on the phone.
>>
>>53091372
>flexibility
This is actually true, although I would personally call it the ability to keep on 'hacking something together", but there are a lot of problems shown in that document.

The utility class is a unreadable piece of garbage. This is mostly the programmer's fault, but C++ is notorious for badly written code.

You need this unreadable utility class to get the index of the element, the added C++11 implementation doesn't support this.

>"range-based for loops are not designed for that purpose."
I really start to question why they even added the range loops to the language if you aren't going to cover most use cases for for-loops.
It´s clear that will all these added v11 features the designers wanted the language to be more modern, and let it do stuff dynamic languages like Python or 2000s static languages like Go and Rust can.
All those languages can return the position of a element in a range-based loop. Hell, Rust doesn't even support C-like for loops.

Now if you want to get the position of a element in C++ you'll either have to hack something together or just skip automatic boundary checks a go back to the old for loop.

And that is the biggest problem C++ has, it has tons a features glued on and hacked together that aren't even feature complete. It takes years to fully get what C++ has to offer, and that fact makes it a bad programming language. It is a complete mess.
>>
>>53091001
>>53091099
Holy fuck I know her, she lives in Finland and is only 17, DON'T ASK FOR NUDES YOU PEDOS.
>>
>What is C++ used for in the industry besides GAEMS
A lot of performance-intensive desktop applications. Anything to do with image manipulation, 3d rendering, video production, etc... that shit can be quite demanding in terms of hardware utilization, so a language which performs well is preferred. That pretty much means C, C++, and a few others are all one can really work with. Since C++ also happens to make abstraction easy for the very large codebases behind these applications, it's the language of choice.

Oh, hey, on that note, it's also often used for the interpreters/virtual machines for other languages. Your web browser... it's probably written in C++. So's the JVM and the .NET Core.

>It's not used for web development
Well actually, Apache is written in a combination of C and C++ (mostly C++).

>or phone apps
On some Android applications, where performance is actually needed, C++ is used with the JNI to speed up a few areas.

>so what's its purpose?
C++ has the speed and control offered by C, but with a level of abstraction that makes it suitable for larger codebases.
>>
>>53091001
>What is C++ used for in the industry besides GAEMS?
virtually everything
https://web.archive.org/web/http://www.lextrait.com/vincent/implementations.html
>>
>>53091803
>PEDOS
Sperg detected
>>
>>53092461
Shut the fuck up you degenerate piece of shit. Your kind is less than human, and should be exterminated whenever discovered. One need only look at the Arab/Muslim world to see what happens when pedophiles are tolerated, or even worse celebrated.
>>
>>53092666
>pedo is a kind
Fuck off back to tumblr you unlikable SJW cunt
>>
>>53091831
> speed and control offered by C

Not, it is slower and spits out larger binaries due to pulling in a larger standard lib. With that said, it isn't much slower/much larger and

>with a level of abstraction that makes it suitable for larger codebases

A decent trade off.

>>53092743
>>53092666
>>53092461

Chill tards, go to /b/ or /r9k/ and discuss whether or not it is okay to fuck children. Talk tech here faggots.
>>
>>53092951
I think by speed, he meant speed of development.
>>
>>53092951
>and spits out larger binaries
I could see how larger binaries could be a problem working with embedded systems, but with phones and computers having gigabytes of memory to work with, does a slightly larger binary matter that much?
>>
>>53091001
ackshually, you can use C++ to write any software, including phone apps, and web development (with the right transpiler)
>>
>>53093033
I remember there being a copypasta response to this question.

Anyway
>bloating your code because the hardware can handle it
Hello Microsoft
>>
>>53092743
Awww, pedophiles don't like me. I'm just totally crushed. Do you think serial killers, terrorists, and drug lords dislike me too?

btw learn what the fuck a sjw actually is before you go casually tossing it around like the stupid inbred hick you are. Die in a fire while you are doing so.
>>
>>53091001
nigga wat do you think your fucking "html is a programming language" bullshit runs on? A fucking webserver written in C++
>>
>>53093100
Well, it's not bloating your code for the sake of bloating your code, otherwise, we would simply make every program using assembly.
>>
>>53091159

How about no.
http://www.tux.org/lkml/#s15-3
>>
>>53091001
I've used [a subset of] C++ for writing embedded stuff at multiple companies. If you're careful about how you write the code you don't incur any overhead over a similar implementation in C and the type system, template metaprogramming, and constexprs make doing compiletime stuff much easier than doing something similar using the C preprocessor. That said, the language is a pain in the ass and I wish it didn't have to suck so hard.
>>
>>53092951
Any linker worth its salt will gc the unused shit from the standard library if you're linking statically and if you're linking dynamically then who cares?

And if you really don't want to deal with the overhead of the standard library just don't link to it. The amount of stuff you need to implement on your own is pretty minimal if you don't use exceptions or rtti. __cxa_pure_virtual if you want virtual functions, __assert_func for assertions (unless you're getting that from the C stdlib) and a few other trivial things.
>>
>>53091208
I don't understand C++
was there something wrong with
vector<int> list;
int index = 0;
for(auto& elem:list) {
int i = elem;
...
index++;
}

?
can't you use [] with vectors anyway? I thought they were just resizeable arrays
>>
>>53091001
Most applications though things are moving toward Java.

>But muh performunce
Java performs quite well when programmed correctly. No amount of language efficiency can counteract shitty programmers.
>>
>>53091208

You'd have the same issue in java and C#. Only language I can think of that has support for this is Go.

Whats the issue here? >>53093746 is the solution.
>>
>>53093746
you can but you can also use iterators since it's from the STL.
>>
I am a physics student and they teach us c++ in order to later make other stuff that does specific things.. there is already ton of super specific lab software out there but c++ is like a multi tool in case you dont have other stuff you might need.
>>
>>53093780
and D
your_type_here[] array = ...;
foreach (int index, your_type_here element; array)
{
//do some stuff
}
>>
>>53092951

>it is slower
While the STL is not particularly optimal, and does not perform as well as C libraries in benchmarks, the language itself can be considered to be equally as fast as equivalent C. Many companies which use C++ heavily may have their own in-house STL implementations optimized for their particular needs.

>larger binaries
This doesn't really affect performance much at all, and if you're doing dynamic linking, the binary size difference between C++ and C may be negligible.
>>
banks use C++ to crunch numbers
>>
File: Don't post full pictures.png (933 KB, 694x697) Image search: [Google]
Don't post full pictures.png
933 KB, 694x697
>>53091099
No, full pictures make her seem distant and unwelcoming. Cropped pictures of her face are more intimate.
>>
>>53091803
>i know her
bullshit
get nudes for proof
>>
>>53091001
lol @ this bait thread

>It's not used for web development or phone apps, so what's its purpose?
what do you think the services that run google/AWS/facebook are written in?

(the ones your phone and website make use of)

supposing this isn't bait and you're just ignorant, visit highscalability.com some time and check out the tech blogs they link to. the world outside of CRUD and webdev is interesting, and makes use of more than just ruby and node
>>
>>53091001

OkCupid was written in C++
(the analytics part)
>>
>>53094248
does anyone else think she looks like she could be Linus' daughter?
>>
Nothing. C++ is used for nothing, not even games.
>>
>>53094444
Quads can't lie.
>>
>>53092666

What the fuck did you say about me etc etc

Get out normies
>>
>>53093146

>being this buttblasted about random people appreciating gorgeous lolis

Is this Facebook?
>>
She looks like Linus Torvalds
>>
>>53091001
for example, google analytics and other ads related systems are done largely in C++. their regional head engineer here is a world famous C++ programmer. etc.
>>
>>53093372
Linux is a kernel retard, not an OS
>>
>>53094262
>Implying I have nudes of a SEVENTEEN year old girl who I have only met twice.
>>
>>53091001
So what you are actually implying is there's nothing besides games, web and phone apps.
>>
Everything that requires good performance.

Of course less and less applications actually do.
>>
>>53092170
>JVM is written in C++
So why does Java even exist? It's just shitty C++ what's the point? Just so lazy programmers can get away with not cleaning up?
>>
You use C and C++ because Java,C# programs can be Rev engineered as easy as cutting pie.
>>
>>53091099
not using png
>REEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE
>>
>>53092666
>17 years old
>degenerate

Kill yourself low test feminist mangina.
>>
>>53091001
I would bet probably 85% of the software you use daily is written in C++
>>
>>53097195
and C/C++ programs can't?
Thread replies: 58
Thread images: 3

banner
banner
[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y] [Home]

All trademarks and copyrights on this page are owned by their respective parties. Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
If a post contains personal/copyrighted/illegal content you can contact me at [email protected] with that post and thread number and it will be removed as soon as possible.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com, send takedown notices to them.
This is a 4chan archive - all of the content originated from them. If you need IP information for a Poster - you need to contact them. This website shows only archived content.