[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
I have to learn c++ for my new job. What are some good projects
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: 7
Thread images: 1
File: 1315275660940.jpg (10 KB, 171x251) Image search: [Google]
1315275660940.jpg
10 KB, 171x251
I have to learn c++ for my new job. What are some good projects to do to learn it?

Any good resources for learning how to write it well? I just got a copy of effective c++
>>
>>54382826
Write a wrapper around the pthreads library (e.g. a Thread class, which you can derive from to do stuff).

Then use your wrapper for some parallel programming. A crappy n by n matrix multiplication is a good, ugly loop you can parallelize. Or just do a parallel fizzbuzz, who the fuck cares.

The thing you should understand about C++ is that it's really just C structs with a bunch of nice protection, virtual methods, and ugly ass templates.

The pthreads API is a classic object-ish interface, and if you can understand how structs in the pthreads API works, you will understand better how C++ actually works and why people make fun of it for being C with bullshit attached.
>>
>>54383070
>you will understand better how C++ actually works and why people make fun of it for being C with bullshit attached

It's not bullshit. Especially modern c++
>>
>>54382826
C is shit compaired to ++

a string in c is like
char [7] = "string";

in c++
string = "string"
>>
>>54385930
Yeah, I suppose.
>>
>>54382826
Chip8 emulator
>>
>>54385930
const char * str = "you're a nigger"
Thread replies: 7
Thread images: 1

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.