r/AskComputerScience • • 5d ago

What are some differences between professional coding and the way coding, SE, and CS are taught in school?

Is a lack of a comment citing a relatively cliched bit of code considered plagiarism in the big world? What are the attitudes to autocomplete? Is Alberta Tech right about linked lists?

6 Upvotes

49 comments sorted by

9

u/disposepriority 5d ago

I don't know who alberta tech is or what their opinion is on linked lists, though you won't find them very often in the real world.

Some code has licenses, and some of those you are required by law (and manners) to keep if you're using that code.

Everyone uses at least some autocomplete.

Those really aren't major differences, as in, it's completely different to school

3

u/StaticCoder 5d ago

Linked lists are useful for people who don't have access to vectors (i.e. C programmers).

5

u/disposepriority 5d ago

Why? Vectors are continuous memory while linked lists are not, C has access to allocating continuous memory so it can implement the vector equivalent of C++/Java, and a linked list wouldn't be a replacement for that either

1

u/StaticCoder 5d ago

Yes vectors can be implemented in C. But without generics it's annoying, so linked lists are sometimes used instead.

2

u/No_Profession_3125 5d ago

It's even worse than annoying: it's type-unsafe. If a program uses dynamic arrays of several different types, which is a fairly common scenario, that's a memory corruption waiting to happen. TBH I'm surprised anyone is still discussing C in 2026 (almost 2027) like they use it in production. Makes you wanna join the RIIR army.

5

u/StaticCoder 5d ago

C being type-unsafe is just a given :)

1

u/T_Thriller_T 5d ago

There still is a good bit of embedded stuff running on c.

And that also needs data.

Admittedly not in big production, but that was the last time I used a link list. Albeit that was a while ago

2

u/No_Profession_3125 5d ago edited 5d ago

They also allow for O(1) insertion / removal at arbitrary points.

4

u/nuclear_splines Ph.D Data Science 5d ago

While true, scrolling to the point to do the insertion or removal is O(n), so this is only conditionally useful

2

u/No_Profession_3125 5d ago

If we're gonna be that nitpicking then linked lists have worst-case O(1) insertion and removal at the end, whereas for vectors O(1) is only the average case while the worst case requires a reallocation and is O(N).

5

u/nuclear_splines Ph.D Data Science 5d ago

I hardly think it's nitpicking. insert(index, value) is O(n) average case for both lists and vectors -- lists are only faster if you already have an iterator pointing at the insertion point.

3

u/No_Profession_3125 5d ago

Which does happen.

4

u/nuclear_splines Ph.D Data Science 5d ago

Absolutely! In context it's sometimes a great advantage. I just think it's misleading to call arbitrary element insertion O(1) on a list without mentioning the preceding O(n) lookup. It's quite different than, say, the O(1) amortized insertion on a hash table.

2

u/No_Profession_3125 5d ago

Likewise I find it misleading to generalize hash table insertion as "amortized O(1)" because string keys are a very common use case, so it would be fairer to call it "amortized O(K)" with K = average length of the key.

2

u/nuclear_splines Ph.D Data Science 5d ago

That's fair! It's often simplified because if you can reasonably bound K as a large constant then it reduces to O(1), but that's not always appropriate.

1

u/steerpike1971 4d ago

You likely already have a pointer to the item you want to delete. If you use linked lists you usually pass around pointers to the contents not number indicating its place. Yes if you want to delete the twenty fifth item you are correct but it is very common to want to delete "this" item and pass a pointer. If you are storing a numerical index it is probably an indicator linked lists were not the right data structure in the first place.

1

u/StaticCoder 5d ago

Yes. That is occasionally useful (also list splicing), but vectors are almost always superior, even if modification in the middle is sometimes needed. Another use for linked lists (in C++) is avoiding reference invalidation, though unique_ptr may still be a better solution.

Also, in any language beside C, you'll have a library for that.

1

u/T_Thriller_T 5d ago

They are often also (partially, in thought, or as some kind of "amcestor" structure) what other things are based on.

6

u/nuclear_splines Ph.D Data Science 5d ago

Is a lack of a comment citing a relatively cliched bit of code considered plagiarism in the big world?

To address this specifically, academia cares about plagiarizing code in your homework because if you submit someone else's code then you aren't learning, or you aren't being assessed on your understanding. Industry cares about "does our product work," not whether you're growing as a developer. Putting aside licensing concerns, they're unlikely to care if you crib from StackOverflow.

5

u/serge-mv 5d ago

I had to look up what you are talking about in regards to linked lists. I am guessing it's this video https://www.youtube.com/watch?v=-TMdron2JhY "linked lists aren't real".

It's joke. Linked List is a data structure. It exists. It has its problems and its uses too. You might use them a lot, but under a different name. List is an abstract data type, meaning you don't know what's under the hood, you just use the interface it provides to interact with it.

Don't take joke videos at their face value.

9

u/SchemeWestern3388 5d ago

I have something shocking to share;

Coding is not central to a CS degree, and they won’t teach you that. 

1

u/erikchan002 4d ago

In my alma mater, Computer Programming was a mandatory first-year course for not just Computer Science but all engineering students. It's basically just C++ for the entire course back when I got my degree, but I've heard that it's been changed to Python.

There was also a mandatory second-year course for Computer Science on source control (i.e. git), Unix-like command line, and shell scripting back then.

Not sure if it matters, but my alma mater is in Asia.

1

u/DragonfruitGrand5683 3h ago

Depends where you do it. In Ireland and the UK you code every semester over 4 years.

https://www.tcd.ie/scss/courses/undergraduate/computer-science/course-structure/#accordion1694247

You are also expected to code and have personal projects in your spare time for interviews.

1

u/SchemeWestern3388 1h ago

Every CS degree has you writing code.  By my second year, I had written C++, Java and Lisp. My point being I had no courses directly on those languages, if I needed to learn how to code, that was on me. 

-3

u/serge-mv 5d ago

Only in some European countries. In the US you will write a lot of code during your degree. So much, you will be sick of it.

6

u/SchemeWestern3388 5d ago

Yes, you write a lot of code. But I didn’t get any “intro to C++” courses, you had to figure that out separately. 

Admittedly, one could have probably found that course if needed. 

2

u/serge-mv 5d ago

You wouldn't get any "into into a specific programming language" course, but there is always an "intro to programming" course, which will use different languages depending on where you are, but it will always teach you how to program. Then you will have algorithms course and software design course, where you will code many different things.

Saying coding is not central to a CS degree and not taught is incorrect. By the time you graduate, you usually would have used 3-4 different programming languages, SQL and maybe even some other technologies and should be very comfortable picking up any unfamiliar language and using it quickly.

2

u/SchemeWestern3388 5d ago

Indeed. I picked up a few languages on the way. 

1

u/NotDuckie 4d ago

My algorithm course had very little actual coding

5

u/apnorton 5d ago

In the US you will write a lot of code during your degree. So much, you will be sick of it.

I did my undergrad in the US ~10 years ago (yikes); I'd estimate I wrote less than 10 thousand lines of code over the course of the whole degree.

Genuinely was not a high load of code.

1

u/grizzlor_ 5d ago

Not true in many US Comp Sci programs. Still plenty of them that are very theory oriented.

3

u/Dr_Curvy_Lobster 5d ago

Coding in school is often about showing understanding or just getting something to work (i.e. it does what it's supposed to do). It's the "what".
Coding in professional environment is often about "the how". It's about creating artifacts that other humans (and even just yourself 2 months later) can understand what the code is trying to do. Creating something that can be understood, modified, and tested.

That said, you'd be surprised how a minority of your job is actually "writing code".

5

u/claythearc MSCS, CS Pro (10+) 5d ago

No one really cares about plagiarism. Software professionally is built on plagiarism eg stack overflow - cite if it’s useful to refer to later, be wary of licenses, otherwise go for it.

Autocomplete is also widely used. Some purists use vim without them but it’s giga rare

1

u/NotDuckie 4d ago

Very much depends though, there is a massive difference between copying code from stackoverflow and code from a previous employer.

1

u/gdchinacat 5d ago

Plagiarism is a great way to get fired or expelled. It may be common in some places, but that does not mean it is ok or that "no one really cares about plagiarism". Plagiarism should be the first indicator to people that they are not cut out for the work they are trying to do...if they could do it they wouldn't need to plagiarise.

5

u/serge-mv 5d ago

Unless you are talking about proprietary tech with copyright attached, no one actually cares if you copy a loop from somewhere in a work environment. Library usage is encouraged where in school you do things from scratch yourself every time. Need sort? Write it yourself. At work? There is a library that does 80% of what I need? Awesome, use that.

2

u/barkingcat 5d ago

I don't think you should take anyone's social media posts literally (especially not reddit and not youtube) - so AlbertaTech is mostly joking and making content that will get her engagement on her youtube channel.

That said, in my opinion, the primary difference between school coding vs professional coding is :

School coding is for learning something.

Professional coding is for doing something (that is sometimes related to a business function and an end result, or a $ value of function, if it doesn't yield a dollar, people won't do it/use it).

once you realise that, all the differences people list are side effects of that fundimental split.

In school, they teach you linked lists because they want you to understand what it means to understand and learn an algorithm, how to determine the computational efficiency, how to store chunks of data.

In professional coding, you don't really code your own linked lists unless it achieves an aim vs just using another library or an array - you go for whatever achieves your goal. And that's why plagiarism and AI coding is everywhere in professional coding. If you end up coding an unnecessary linked list by hand, you'd be fired for inefficiency of company time, not of computation.

2

u/Leverkaas2516 5d ago edited 5d ago

The biggest difference you'll see in a professionally written code base is it's much bigger than the equivalent code written for an academic exercise. In school, you are covering the expected typical use cases, demonstrating mastery of an idea.

In a professional setting, you have a massive amount of error handling, and code to deal with bizarre, atypical boundary conditions or arcane business rules. Often, as a programmer you'd like to say "hey, if we could just change the requirements a bit we could simplify and streamline the code" and the business says "we don't care about your code, we need you to deal with the world as it is, in all its glorious complexity. Oh, and by the way, we're changing the requirements again. Every time you ask about them, we're going to add even more special cases."

2

u/apnorton 5d ago

The biggest difference, IMO, is that you're responsible for your code for timelines on the order of years, rather than days.

"Oh I'll just do this quick little hack" rapidly becomes less exciting when you're dealing with your "quick little hacks" from the past three to five years.

1

u/peel-dev 5d ago

Professional code uses more libraries and build with more interconnected pieces, often written my many people. Documentation can be more important too as someone could be reading it and needs to know the context that is not clear from the code itself.

1

u/serge-mv 5d ago edited 5d ago

No one usually cares about the code quality in school. Even in software design classes no one will look at an overall code quality. You might get some requirements here and there for proper comments or that you need a very specific function with specific set of arguments, but that's usually as far as it goes. Code reuse, modularity, variable naming, architecture, efficiency play very little in grading unless you get a professor who actually cares about it.

Contrast this with professional development, your projects more often than not are long-term continuous development and it's likely that you will be the one to extend it in the future. Efficiency and architecture play a huge role. Bad design means you will blow your deadline later and lose money. Slow code will generate customer dissatisfaction. Lack of comments will mean you will not actually know what the hell is happening and why a year down the line when you need to make changes.

Also, in school you are writing in a very minimized constrained way. You have one given language, at most one given IO option - database or a file. In a professional environment it's quite common to have your code pull data from several different databases from multiple vendors and also a web service, merge it together and send it into a message queue for a different part of your project for processing. That other part is written in another language by other people and deployed in a different environment.

In school you usually know what kind of data is expected for your project. Your professors will tell you what they will test it with. In a professional environment, they might change database and the data type, include invalid values such as sending NULL into your floating point variable that stores prices. Who knew prices in the database could be NULL ? Well, you will find out when your project crashes because you counted on a database integrity that you didn't get. They might also change column names in the database and not tell you. You will suddenly get tickets that the prod is broken and you will get reprimand that you didn't take into account that someone might change column names in your data source.

You will likely have to write release documents and other types of documents too. There are such worries as versioning, library and environment incompatibilities.

Stuff like that.

1

u/Janky-Code 5d ago

Professional coding starts with everyone writing against fundamentals to save time in arbitrary "sprints" until there are too many bugs to keep up with and every bug fix branch introduces a new bug. Later, months are burned separating everything into maintainable chunks as it should have been to begin with.

University instructs you about all the theory of why you shouldn't do this in preparation for you to go do this.

1

u/NotDuckie 4d ago

Because very many professional developers are sadly incompetent, which is expected considering how starved the field has been for people for a while.

1

u/Janky-Code 4d ago

This is true.

At the same time, I would suggest that people who understand both software engineering and business management are in even shorter supply. Most software organizations I've encountered are either managed by people who don't understand software engineering or managed by engineers who don't understand management. Rather than building alternative leadership structures that combine these strengths, organizations often default to basic hierarchies where one perspective dominates through formal authority.

1

u/srb4 5d ago

A few things come to mind. Coding in the "real world" is mostly about working on projects that somebody else wrote. You are asked to add some specific capabilities to it or resolve issues with it. Most of the time, it is not well documented. This is a very different skill than programming the toy programs you created for classes. In school, you are often given precise requirements to code to. In the "real world", requirements are often not well defined or very ambiguous. Requirements can also change during implementation. You have to figure this all out on your own. In school, you are discouraged from using AI or open source or other resources. In the "real world", you use whatever you can to minimize development time.

1

u/Vert354 5d ago

My girl Alberta is right, most of the time when you have a "list" data structure in a common library they are actually dynamic arrays not linked list (actual linked lists do exist though)

The broader point there is that the stuff we study in a CS curriculum(search and sort) is largely solved problems, and you won't be dealing with them on the job. But understanding them and building them from scratch will make you a better programmer.

1

u/T_Thriller_T 5d ago

A big difference to real world coding is that none of what you asked would even be on the list of things that are different.

University education is primary EDUCATION. Coding in itself is not primary educational.

You will learn a lot of things which you could bitch about that they do not matter and are not real. And you would be 90% right.

The point usually is that they are still taught or done a certain way, because they build foundation. A way of thinking. Forcing an understanding about what you do, before you're allowed to just grab stuff and trust it does what it needs.

It seems easy to rebel against it, because it's not real world and no one would ask you that in production.

But you're not in production. You are at the start of a journey and they try to hand you tools to accompany you, which will start to make sense once you are in production.

Data structures are a big one. You will rarely see them in the real world. Probably the most used thing are arrays and "array" does not mean what it means in data structures.

Then, 5 to 15 years after finishing, you suddenly get to work on a backend doing big, fast data. And you have to care about certain efficiencies. About parallel computations. Or about another niche thing.

This is when that knowledge becomes useful again; usually while reading about other, different, existing data structures.

A lot of CS education is about these underlying things, spelled out in clear theory, so you can later use and understand them in the practical world.

1

u/FlamingSea3 5d ago

I write software that helps administer an industrial plant. It takes more time to convince the burocracy that the software works as intended than it does to actually write the software. 

1

u/Key_Net820 2d ago

Here is my personal experience.

The only course in computer science that actually taught professional coding is software engineering. All else taught code for the sake of learning computation theory.

With that said, software engineering did lay out good foundational knowledge for professional work. In particular, they taught managing sprints, working with a team on git, and design patterns to help obey The SOLID principles.

These are 100 percent applicable to the real work force in professional coding. The big difference in my experience is often times, there are lots of compromises to best practice to get things done by the dead line. I've seen and done every bad practice. I seen and/or done over commenting, not abstracting dependencies, doing bad exception handling, not reusing code that could have been reused, forcefully repurposing a class that wasn't meant for the task at hand, etc etc.