Mfw the new intern unironically uses linked lists

>mfw the new intern unironically uses linked lists

Attached: BStroustrup_MAIN.jpg (720x720, 230K)

Other urls found in this thread:

notes.shichao.io/lkd/ch6/
pastebin.com/raw/8w30ukkM
youtube.com/watch?v=YQs6IC-vgmo
twitter.com/NSFWRedditGif

>linked lists
whats wrong with that.

it's a meme

>force all new hires to learn a bunch of interview question shit that has no bearing on the job
>anybody who can't do it will never get hired
>end up with a bunch of sycophants who studied for interviews instead of getting good
faang

It's just a preference.

Attached: time-to-et-array-those-numbers-l-how-cpus-linked-39708569.png (500x616, 36K)

A pointless, useless data structure that will simply trash your cache and is only good for computer science newbies doing their homework.

>grabs the entire array in one operation

Attached: d8l9t2u-5ee3e78d-2255-452e-a4d4-504229b9c129.jpg (200x249, 7K)

cool story. so you're starting your second year at university. I wonder what excellent posts we can expect after this year. thank you for going out of your way to create this insightful thread.

dilate

I’ve interviewed many people at a faang and we were not looking for interview question skills, we were checking to see if they could program or not.
I’ve approved many candidates for not having an answer memorized but still being able to think on their feet and implement some kind of solution using what they knew.

>what is SIMD
>what are GPUs
>what the fuck how is it 2019 already

>MUH CACHE
array vs linked lists arguments are a prime example of Dunning-Kruger, people who've once heard about something called a cache (maybe even a term like L1 or L3!) and think that's all there is to it.

Mega protip: There are actual function differences between linked lists and arrays, sometimes you need the guarantees of one or the other - stable references and still be able to insert/delete for example.

just use a heap, buddy

don't bother. there's no hope for these people. all it takes is a minute to read a few results of a quick web search of when to use which and differences.

t. python & javascript developers

The functionality linked lists provide are virtually never needed in the real world.

i use std::list when i dont want to deal with iterator/pointer invalidation.
my project is already too complex and i dont want to add extra complexity for meaningless performance gains.

also there are use cases in which list is faster, like when you're not sequentially iterating and do a lot of insert/remove while having to maintain relative order (so no pop and swap).

Python "lists" aren't actually lists, they're just dynamic arrays.

seethe

Current intern on my team makes me want to commit sudoku. Literally can't code. Has submitted multiple code reviews that don't even build. Doesn't understand design patterns at all and pretty much just wants to write everything in one method. Ive had multiple 2-3 hour sessions with them trying to explain how to write good code and they still don't get it. With the time ever spent helping this person, I wouldve been able to implement their project.

This is a masters CS student btw.

cache lines are a thing
if you are doing sequential access the prefetcher will even stuff the CPUs face with the bytes before it even thinks about needing them

Genuine question: Why are universities so trash at teaching cs?
There are literally people out there with master degrees who cant write fizz buzz.

computers are to computer science as telescopes are to astrophysics

ActiveProcessLinks

Where do they teach computers and telescopes?

I just use a hashmap of hashmaps

koding bootcamps and mechanical engineering classes respectively

You sure about that?

so learning to use computers is harder than learning CS?

actually it makes sense, since using a computer is in a sense a superset of CS - you need to know CS and you need to be able to apply that knowledge with the added complexities of the real world.

Attached: 1563696237951.jpg (423x469, 19K)

Same here.

Every intern is supposed to present their work to our office at the end of their term. Current intern hasn't gotten through a single code review without requiring a complete rewrite. Kid can't code.

I think I'm just gonna not have him present. His current "contributions" to the projecf include a function that downloads an image, a function that makes a simple query, and hundreds of hours of headache and hand holding.

Somehow this retard actually did decent in the interview

These "contributions" came over 12 weeks, BTW.

12 weeks go write two functions. Literally 5 minutes of work for someone with a brain.

>since using a computer is in a sense a superset of CS - you need to know CS
right, because the average Arch ricefaggot can explain what a Support Vector Machine is
go fiddle with your xorg.conf some more, brainlet

Attached: 723.jpg (300x199, 10K)

that's insane

the interns on my team arent too good at programming but they incorporate feedback after being told something 2-3 times and are making slow but steady progress

This is typically the progression we see. The kid we have now just doesn't learn. You have to repeat everything you say, and then it still doesn't stick.

using a computer in a sense of programming it you retard (and real programming not webdev).

>Hey I'm a rational middle ground kinda guy who doesn't know what the fuck I'm talking about but am going to parrot some cliche shit like "use the right tools for the right job".
The worst part is you genuinely think you know anything

Keep in mind these people are likely mouth breathing morons themselves which would also explain why their interns failed them. Internships are a two way street.

>The functionality linked lists provide are virtually never needed in the real world.
Might wanna check out some kernel code some time.

What does SVM have to do with CS you blithering retard?

>t. has never used Ocaml or any functional language
>t. has never done OS level programming
>t. thinks he's a good programmer but is in fact incompetent
"As the simplest and most common data structure in the Linux kernel, a linked list is a data structure that allows the storage and manipulation of a variable number of elements, called the nodes of the list."
notes.shichao.io/lkd/ch6/

>most common data structure in linux kernel
git gud... baka

Not a middle road, it's a binary choice.

Every FAANG company I know asks leetcode questions. Are you talking about Amazon? I know they ask more practical questions.

I'd list them all but just think about them the next time you use git or any language or filesystem that has CoW

Linked lists are superior if you will be adding or removing data from the structure.

>OCaml

Attached: It's time to duel.jpg (600x900, 71K)

To all the unironic morons in here, I suggest you publish a paper describing why linked lists are anti-patterns. You might learn something from the process.

They're not anti-patterns, they're a meme. Like Calculus in High School, useless knowledge everyone has to learn that has no practical use for most people.

>thinks Ocaml uses linked lists internally
lots of laughter

>calculus is a meme
...except if you know PDEs well you can make some serious bank in the right fields

*cough* LISP *cough*

well, they are trees, but still.

Absolutely, but I don't think it's necessary for High School where the vast majority of people wont be going into a field that uses it.

If you're a programmer you'll need calculus eventually... Even for webdev

Im trying to complete a programming challenge that wants me to reverse a linked list and it seems stupid as fuck but I want to learn it for the sake of knowing it.

>you'll need calculus as a webdev

Attached: 1528088696261.gif (645x729, 631K)

When?

If you're a webdev and need calculus, it's very likely you can just google the discrete solutions and don't actually have to solve anything yourself.

>tfw making a webGL game

OpenGL isn't webdev tho, even it is on the web. Just like writing a desktop app on Electron isn't web dev.

>Gaymes
wew lad, talk about memes

you can see the code here

pastebin.com/raw/8w30ukkM

Any optimised Lisp implementation will use list unrolling. And before that they used cdr coding.

Oh sorry I thought I was discussing with an adult

just tell them do to the needful

Yeah, I saw that video as welll.
News flash: if most of your operations consist in insertions, and you rarely ever have to traverse the entire list, a linked list is much better than a vector.
Next time try actually thinking for yourself instead of parroting what you saw on YouTube.

I remember believing the same thing when I was an undergrad.

oi

>the Linux kernel
Linux itself IS a kernel, let's not be redundant please.

Linux is a Kernel
GNU's Not Unix

There are no CPUs in C++. There is no reason to think about CPUs in C++.

Linux is a family of open source operating systems that all run on the same kernel - the Linux kernel. From wikipedia.

There are two kinds of code.
The code that must run fast, and the code that won't take much CPU time and you're better of making it as maintainable as possible.

And linked lists aren't good in either.

trash your cache XD

Watch this video.
Basically if you use a vector instead of linked list, it will utilize the prefetching feature of the processor, hence improve performance. After watching that video a couple of years ago I thought I am the smartest kid in my class, because I knew no one else had even thought about that before, now I just know it is a random information that may or may not help me in my career :) am sure though it helped me feel smart today :))))))

ooops I ment this video
youtube.com/watch?v=YQs6IC-vgmo

Linux is a kernel.

>Bjarne Stroustrup
>The Man From C.+.+.
D RO P P E D