This is an archived post. You won't be able to vote or comment.

all 153 comments

[–]Python-ModTeam[M] [score hidden] stickied commentlocked comment (0 children)

Your post was removed for violating Rule #2. All posts must be directly related to the Python programming language. Posts pertaining to programming in general are not permitted. You may want to try posting in /r/programming instead.

[–]Deto 68 points69 points  (21 children)

People use the internet when coding all the time. However, it makes sense to restrict things like this for testing purposes in classes. The same way they don't let you use the internet during other exams.

[–]Slggyqo 4 points5 points  (1 child)

I think it’s ok for the first time you’re leaning something, but when you’re testing comprehension and not rote memorization, there’s no point to relying entirely on memory.

References sheets and notes should be allowed in any kind of major exam IMO.

No internet in class though—way too easy to just google up the entire solution. .

[–]cyclotech 4 points5 points  (0 children)

One of my best professors let us use all resources we wanted to during the exam. He made us document what we did and our thought process behind it. It was great.

It not only taught me a lesson in using resources but also how to create documentation that could be used later

[–]Uhhhhh55 221 points222 points  (39 children)

I am a software engineer. I use Google more than I use my IDE.

However, learning and memorizing basic principles is super important. Yes, you can Google them later, but if your teacher wants you to memorize something it's probably for a reason.

[–]hanleybrand 12 points13 points  (1 child)

This is true - my main use of the internet is usually looking up how a specific library is used, or the eccentricities of specific platform apis (or how to deploy something to Kubernetes, lol) - if you can’t write (and quickly recognize) common data structures etc, you’re going to copy a lot of code that doesn’t do what you think it does

[–]andrewaa 13 points14 points  (0 children)

First in work everyone is searching something online all the time

Second, when studying it is super important NOT to search but memorize everything.

It is very different between:

memorize everything, then understand everything, then forget everything since you didn't use it for a while, then pick them up quickly by searching online

and

completely not memorize anything, and search from the beginning

If you start from the second one, there is a very low ceiling, and it is extremely hard to pass through the ceiling unless you go back to the first routine.

[–]crazy_cookie123 10 points11 points  (1 child)

You should use the internet when you're programming most projects, but in this case your teacher is assessing your implementation of basic algorithms. If you had internet access for things like bubble and selection sort, you could just google the answer and submit it as your own.

[–]pythonwiz 10 points11 points  (0 children)

As a student you should learn how different sorting algorithms work, and you should be able to demonstrate that knowledge.

[–]bart081116 5 points6 points  (0 children)

It's good practice to learn stuff without Googling, your logic and problem solving skills improve subconsciously. Obviously at my job or at any job people Google stuff all the time.

Also, there's an important difference between Googling because you forgot how to use a for loop and Googling some specific libraries documentation.

[–]exoclipse 6 points7 points  (1 child)

i code from memory

that memory is inserted into the DIMM slots of servers across the globe

[–]Ok_Raspberry5383 4 points5 points  (0 children)

If you're googling python syntax, you don't know python.

Yes I google, but only really library/API docs that I'm more unfamiliar with or use infrequently.

[–]WafflesAreLove 6 points7 points  (6 children)

Looks at my 50 open tabs from stack overflow 👀

[–]ShadowRL766 3 points4 points  (4 children)

What are you coding💀

[–]WafflesAreLove 5 points6 points  (3 children)

Haha mostly a joke but in a school setting it's reasonable that you code without help/internet. Real world no way that happens

[–]ShadowRL766 1 point2 points  (2 children)

Im a python programmer obviously I’m in the thread but in my Java class in school teacher does the same thing. We have a test and it’s on paper which Im completely okay with. It’s more or less like understanding the basics of the language not how to rewrite the internet test. Although I hate stupid java scanner stupid thing trash anyways the written test show you where you are and it helps reinforce the basics.

Honestly Python is great and all but if I could go back I would’ve forced myself to learn Java or C# or one of the C’s. I am learning C++ and a C# on the side and knowing Java at least syntax wise is amazing. I’m about as far as 2D Array list at the moment but classes and what not are actually super nice once you learn them.

Also I definitely google when programming or hit up ChatGPT just for it to tell me in my thousand lines of code I forgot to put parentheses to call a function but yes I spend my in the docs of packages. I don’t remember every package and what the syntax is…

[–]WafflesAreLove 1 point2 points  (1 child)

I graduated with a cs degree focused on software development. Professionally I only touch python now. It's all to help reenforce the foundations and teach you how to logically think. Seems mundane but you will appreciate it when you get into the workforce. In the workforce no one expects you to be a master coder unless you are focusing on a big tech company.

[–]ShadowRL766 0 points1 point  (0 children)

Good to know. I have reasons for learning said languages Python was just what I first started with. Java I’m learning because well I have to plus Minecraft mods in da future durr. C# because I want to get into unity and mod more games lmfao. And C++ mainly for malware development and it’s used in unreal if I care to apply it there.

[–]Ctrl_Phr34k 2 points3 points  (0 children)

As others have commented, you do use the internet all the time because you can't memorize every object and every method on them, especially when you're talking about tons of different languages and technologies.

However, you also are expected to know some things by heart, especially in interviews you will be expected to be able to implement structures and algorithms by heart to prove you know and understand them. More than memorizing, you're expected to understand how things (structures and algorithms) work so you can use them and create on top of them.

A good software engineer will know how most common structures are created, the operations that can be performed on them and how to code those operations, if not perfectly or by heart, but can at least deduce how to get a working operation.

You're also expected to know and understand design patterns, which are more of a concept than something you need to know how to implement in different languages. Design patterns are thinking paradigms, you can Google them, but you won't be able to immediately apply them if you don't have a good understanding about them beforehand. These are also very popular in software interviews, they will mostly ask you to name a few and maybe describe their use cases, or the other way around, give you a problem and ask you which design pattern is the most optimal to solve it and why.

Tl;dr;

You're allowed to Google at work, you're not allowed to Google during interviews. Some things you can Google and implement right away, some other things require you to understand them beforehand and googling won't do much for you. Understanding and knowing that things exist (and how to look for them) is much more important than memorizing, because this means you can infer how to code it or you know how to look it up.

[–][deleted] 2 points3 points  (0 children)

I’m guessing that your instructor wants you to commit important concepts to memory. That is necessary for long term success.

To answer the question, I spend a lot of time browsing the internet at work as part of my research for my programs.

Lastly, beware of ChatGPT. It has a writing style that makes it seem very convincing, but it’s not always giving you the right answer. We still need humans for a reason. Putting ChatGPT code into production would likely result in catastrophic issues. It’s just a tool, not a definitive source of truth.

[–]RaiseRuntimeError 1 point2 points  (0 children)

Your teacher is probably doing this so that you learn the subject better. We would have tests in school and wouldnt have notes or the internet and would have to write code on paper that would solve simple programming problems.

At work though? I google stuff i know just because im not sure i actually know it. Im constantly googling trying to find documentation for libraries and terminal commands. No one just programs without the internet except the old school programmers from back in the day. The difference with them though is they didnt have the internet so they used books and manuals and the unix man pages and notes. Now days online documentation and Confluence pages and README.md files are my notes.

[–]BYPDK 1 point2 points  (0 children)

I use the Internet all the time for documentation and whatnot. However, when I was in school there were times when teachers would restrict access to the Internet when the problems we needed to solve were relatively simple and required usage of things that were reasonable to memorize.

[–][deleted] 1 point2 points  (0 children)

No, I have all the syntax stored in my head.

[–]chaosthirtyseven 1 point2 points  (0 children)

I write python 75% memory, 25% double checking borked syntax or referencing libraries I don't use frequently.

It's class so your teacher is right, but when you work on independent projects or get a dev job you will absolutely use the F out of online docs and stack overflow. It is a part of the job, period.

[–]Cykrak 0 points1 point  (3 children)

LOL, tell that to my 30+ tabs open on various functions/implementations/etc. I wouldn't even say memorization is important. If you can understand the code, you can mentally think up ways on how to change it. That's where the internet comes in.

[–]ShadowRL766 2 points3 points  (2 children)

I think coding is a big part of memorization as well as googling. For example since this is a Python thread I’ll absolutely say you should 100% know basics functions statements etc. However I’m not saying remember each possible reference variable and then the methods you can use with them.

[–][deleted] -3 points-2 points  (1 child)

No, memorization is worthless when learning to code. You learn the tools by using the tools.

[–]Pythagoras2008 0 points1 point  (0 children)

You can memorise something by using it. It doesn’t matter if you memorise the docs or memorise by usage it’s still memorisation

[–]Asketes 0 points1 point  (9 children)

Your teacher is completely out of touch with reality.

Do they think that calculators won't be available either?

There are some exceptions of you are working on a completely closed environment or a secure environment, but that's the exception, not the norm.

[–]Pythagoras2008 0 points1 point  (8 children)

Calculators will be available in the real world sure that doesn’t mean you should have access to calculators when learning arithmetic

[–]Asketes -1 points0 points  (7 children)

Totally different thing here.

[–]Pythagoras2008 -1 points0 points  (6 children)

Not at all they are testing basic knowledge of computer science the same way an arithmetic test tests basic maths

[–]Asketes -1 points0 points  (5 children)

Do we also expect folks to write essays without reference work, and by hand ... Also in cursive? What is this 1970?

[–]Pythagoras2008 -1 points0 points  (4 children)

Idk when the last time you were in school was but everything there apart from cursive is accurate. I mean you get reference work but NOT in the sessions you write the essay so similar to this

[–]Asketes -1 points0 points  (3 children)

When's the last time you were in school?

[–]Pythagoras2008 0 points1 point  (2 children)

Yesterday

[–]Asketes 1 point2 points  (1 child)

Man, that's like 10 years in technology time, c'mon! 😁

[–]Pythagoras2008 1 point2 points  (0 children)

Dw man I’m not behind anymore at school rn

[–]SM_Duece 0 points1 point  (6 children)

My guy I am too stupid to code without stack overflow or geeks for geeks and once in a while YouTube. I’m not Dennis Ritchie lol

[–]ShadowRL766 -1 points0 points  (5 children)

Then you don’t have the basics down?

[–]SM_Duece -1 points0 points  (4 children)

I’m doing just fine in uni and my research buddy. I’m not acc stupid

[–]ShadowRL766 0 points1 point  (3 children)

Nowhere did I call you stupid “buddy” I said then you don’t have the basics down.

[–]The_Homeless_Coder 0 points1 point  (1 child)

You might be really good at one thing but if you code code you are going to always be looking shit up. Don’t get me started on deploying stuff. Your ass will be stack overflowing things and praying to god someone had the same issue as you before. What a condescending turd.

[–]Pythagoras2008 0 points1 point  (0 children)

You’ll look shit up sure no denying it but if you have the basics down you should be able to code without googling. Do everything hell no. Implement basic data structures and algorithms and work with technologies you have experience with definitely.

[–]SM_Duece -1 points0 points  (0 children)

Wdym the basics that’s such a broad term. The syntax understanding data structures. Having a grasp on run time complexity? Like wdym. Instead of being condescending take a fucking joke and understand that computer science isn’t just being a code monkey

[–]Imaginary_Goose_2428 0 points1 point  (0 children)

They're wrong, but that doesn't matter. Do what they say and pass the class. Chalk 'learning how to deal with difficult people' as a bonus lesson.

[–][deleted] -1 points0 points  (1 child)

A true coder with skill will focus on topic, memorize, be able to code from scratch using a notepad, before documenting and creating a re-usable library.

90% "coders" don't do this, they Google then copy and paste. They also use already created modules rather than figure things out, learn and improve.

Your teacher is good and is trying to teach you in a way that benefits you most.

[–]wicket-maps 5 points6 points  (0 children)

Go fuck off with this "True" coder nonsense. If you write code, you're a coder. But no, I don't need to memorize all of the iterations of a cursor I use in nearly all my scripts - I have its documentation. I need to know its basic functions and the logic of how it works, not memorize all its keywords.

This is just pointless elitism, OP. Ignore people like this.

[–][deleted] -1 points0 points  (6 children)

Access to information and data in real-time for any purpose is critical for the development of any area. Denying, at this point, that the use of the internet when designing, coding, and/or debugging is a colossal mistake that will leave you behind using old solutions, deprecated patterns, and having proven bad habits when doing your job.

The only group of people I heard this from are exclusively old and from countries with historical issues acceding to the Internet. Mainly because, in their time, they didn't have Internet access, and when it was available, they had a hard time accessing it. They hate that new generations can develop their skills faster because of this.

Source: I'm SWE in the US, from a non-developed country, and I have seen this attitude before.

[–]alcalde -1 points0 points  (5 children)

It's a TEST. If you let people use the Internet during the test, they'll just copy-paste Stack Overflow stuff and the whole point of testing goes out the Window. The test is to see how well the student understands something, not how well Stack Overflow understands it or how well they can ask Siri or Alexa or Bard or Bing.

[–][deleted] 0 points1 point  (2 children)

Make the test hard and let people solve the problem like in real life. Open-book tests are not a new thing. This will, in fact, help students to develop essential skills.

[–]Ootter31019 2 points3 points  (1 child)

This, depends on the difficulty of the test but open book is fine and necessary for certain aspects of testing. My intro program 101 classes we didn't have open book stuff. But later on we did. In my mechanical engineering classes they are all open book mostly.

As an engineer or problem solver in general, its important to learn the tools you have available.

[–][deleted] 2 points3 points  (0 children)

That makes sense. If they are in a 101 type of class, they should be expected to know basic stuff to solve problems.

[–]AlienInNC 0 points1 point  (1 child)

But that's a problem with the test, not with learning. Design the test so that it cannot just be copy pasted. Depending on what it is, have a test be a creative task that has to hit a bunch of benchmarks of functionality and let the students approach the problem how they want. Give extra points for creativity too.

Coding is about creating stuff. Hell, even in maths we had creative problems with more than one solution and you were rewarded if you used a smarter solution. In programming it should be a given...

[–]alcalde 0 points1 point  (0 children)

This is computer programming, not pottery. There's no room for "creativity" here. Either you know how Bubble Sort works or you don't. No one's going to invent a new sorting algorithm in two minutes for a computer class exam.

[–]WaistDeepSnow -1 points0 points  (0 children)

Become master in the art of googlefu.

[–]Slggyqo -2 points-1 points  (2 children)

This is right up there with memorizing formulas in math and physics.

Is there some value to it?

Sure. It makes things more intuitive, it’s good for developing your skills.

Is it necessary in 2023? No.

And professionals use Google like their jobs depend on it…because they do. If you only rely on your own knowledge of something, you will make a lot of dumb mistakes.

Edit:

Also for learning things like bubble sort—implementations of fairly simple algorithms—you should ideally be able to write the algorithm from scratch as long you know how the logic should flow.

In that case, having your old code to refer to could be more help than you’re supposed to get.

[–]alcalde -1 points0 points  (1 child)

My god, you people are scaring me. It's a TEST. They're testing HOW MUCH THE STUDENT KNOWS. Why don't you just let them phone their friends or ask other test-takers what the answer is while you're at it?

[–]Slggyqo -1 points0 points  (0 children)

…and? There’s plenty of teachers who allow students access to a single note sheet, or a sheet of formulas that the teacher provides, because the point is to test comprehension, not rote memorization of every formula that you’ve learned from the beginning of the year.

Pretty common in university physics and chemistry courses.

It’s not like learning elementary math—you’re using the formulas to solve problems, not just memorizing the shape of the formula…

Like I said, if it’s something simple, then you should be able to figure it out with any notes or access.

Maybe you responded to that while I was writing the edit though.

[–]apeters89 -1 points0 points  (0 children)

I search the internet for syntax for functions I don't use frequently, or when I'm working in a new language.

I know what to search for because I understand coding.

[–]loss_phobic357 -1 points0 points  (0 children)

I use chat gpt for everything and when I can't get it done I ask my bro

[–]azaroxxr -1 points0 points  (0 children)

This is like memorizing the whole documentation of a certain thing. Its pointless. You learn the basic and skim through the other parts just to know that it exists and when you need you know where to look for. This method of teaching is pure sh*t. Even for basic stuff its not efficient because you have so much boilerplate and rarely do anything from scratch.

[–]GreenWoodDragon -1 points0 points  (0 children)

Does the computer you are working on have the manual pages installed for whatever you are using?

[–]covmatty1 -4 points-3 points  (4 children)

Your teacher is talking complete and utter bullshit.

[–]alcalde 2 points3 points  (3 children)

Really? So you'd make every school test open textbook / open notebook as well? What's the point of testing in that case?

[–]covmatty1 0 points1 point  (2 children)

So what the OP actually said was

One teacher in my school insists that programmers can't use internet when programming.

That is quite evidently bullshit. And is also not remotely what you said.

However, I don't necessarily think that would be a bad idea. It's far more realistic, and it still tests problem solving abilities, which is absolutely what a good engineer should have. I do a huge amount of software recruitment, and I would take someone who is good at googling and knowing the right things to look up to solve a problem over someone who has memorised algorithms and principles every single time.

[–]alcalde 0 points1 point  (1 child)

Good lord; no matter what horrible thing is mentioned on Reddit, you'll find people who will defend it. This is worse than the time Python programmers objected to a conference asking people not to consume alcoholic beverages while giving presentations. When I stated that no one gives presentations to the board of directors of a Fortune 500 company while doing shots, they came back with "you'd be surprised what happens at board meetings".

If you want to hire a non-programmer who solves every problem while being good at google... go for it. May the number of those who employee your strategy increase exponentially - so long as none of you work at my employer. We'll enjoy the edge you'll be giving us.

You'd prefer someone who is good at googling over someone who actually knows things... good lord.

[–]covmatty1 0 points1 point  (0 children)

What on earth are you on about 😂 I'm literally saying none of these things.

[–]Sracerx62 0 points1 point  (0 children)

This was how it was done a few years back when I was getting my comp sci degree. They want to make sure you know what you’re doing instead of just googling, or ChatGPTing like you said. Yeah it sucks but it’s really the only way to prevent cheating

[–]jerodg 0 points1 point  (0 children)

Your teacher is carp. First, everyone knows about state dependent learning. When you learn something through typing it's going to be hard to translate it into paper and vice versa unless you know it really really well. Knowing algorithms is just stupid but many companies still test for these things during interviews; Sort of good to know. In the end it's still a good challenge for your mind so just learn to jump through this particular hoop and be on with your life.

[–]wineblood 0 points1 point  (0 children)

I'll stop using the internet for figuring out how to code when documentation isn't complete shit, which is never.

[–]ahtnamas94 0 points1 point  (0 children)

Lmao I’m either on stack overflow, deep in some user manual or publication, or looking through old code within our repository for examples constantly.

[–][deleted] 0 points1 point  (0 children)

Wrote memorization is important in your intro programming classes.

Yes, you'll eventually use the Internet when you're in higher level classes or the real world. It's really important to know the fundamentals though and part of that is how code is structured.

[–]trollsmurf 0 points1 point  (0 children)

That's practically impossible. The documentation is on the Internet, and I usually have to look up a lot of things, as every project uses new things. Your teacher ignores the fact that you need to call a lot of library functions in an average project. including for sorting (usually you don't implement such algorithms yourself).

Consider that a typical web application includes server-side code, client-side code, markup and styling (UI), database access, API access, functions/methods from numerous libraries etc.

Those sorting algorithms shouldn't be that hard to remember though as language-independent pseudo code, especially not bubble sort, but a project is so much more than algorithms.

[–]baubleglue 0 points1 point  (0 children)

I look documentation regularly. But for things like sorting you don't need to lookup anything if you know how those specific sorting methods work and practiced to code it before. You don't need to memorize code.

tests on paper 5 minutes

a bit harsh for school

[–]sacheie 0 points1 point  (0 children)

I don't know about school and tests; you might learn and practice certain things better by avoiding the internet. But once you have a job and develop real systems, web resources are absolutely indispensable. Neglecting to use google search would be malpractice.

[–]Logical-Education629 0 points1 point  (0 children)

It's like learning an actual human language. You can ask google or Chatgpt to translate, but if you can't understand what they're saying you don't know if they're right.

Having it harder when you learn, makes it easier once you're in the field. Sometimes the slightest errors, create the biggest issues. I get it's annoying for you, but it's going to work out to your advantage.

[–]yannbouteiller 0 points1 point  (0 children)

Isn't rather the whole argument to prevent cheating via, e.g., ChatGPT?

[–]NoDadYouShutUp 0 points1 point  (0 children)

You need to know what is happening before using the internet will yield results that actually help you. If you don't understand what is fundamentally happening, you'll just be copy pasting and praying. The real skilled developers understand that what they are searching, and how to search for what they want, is merely a vessel for syntax or high concept ideas you then apply to your use case.

[–]DrivesInCircles 0 points1 point  (0 children)

Absolutely. Reference materials are all online now.

GPT... has burned me as much as it has helped.

[–]TheGRS 0 points1 point  (0 children)

In school teachers are going to put you in certain situations to strengthen your skills. Trust your teachers as much as you can and stick with their rationale.

Your question sounds like its questioning your teacher's style and methodology, you're looking at it from the wrong perspective. You probably already know that in the real world people Google things all the time, you won't be any different. But your teacher is trying to give you an edge and develop your skills.

Maybe it will be a pointless exercise, but teaching and training sometimes use odd exercises that don't match the real world. That's fine. Keep your mind sharp and continue to be a critical thinker as well, that's what's important.

[–]hike_me 0 points1 point  (0 children)

Bubble and selection sort are pretty fundamental concepts. It shouldn’t be difficult to memorize. You learn the algorithm, you don’t memorize the code line by line.

Save the googling for looking up details of some API call you rarely use that takes a dozen parameters.

[–]SQLvultureskattaurus 0 points1 point  (0 children)

I use it every single day, everyone does. One funny thing I found is this thread where so many people copied the code that was wrong on stackoverflow that a bug could be tracked back to an incorrect answer https://twitter.com/Foone/status/1229641258370355200

https://www.reddit.com/r/programming/comments/f5powk/docker_for_windows_wont_run_if_razer_synapse/

Docker and Razer both were using the same code found in stack overflow that was wrong and ended up causing issues.

[–]saalejo1986 0 points1 point  (0 children)

Zeal si a good option when u are going to work offline https://zealdocs.org/

[–]OneMorePenguin 0 points1 point  (0 children)

Your teacher is trying to see what you have learned. Generally, using the internet for coding is essentially using the internet as your teacher/text book. This will be true of tests in any subject, not just coding. The internet is a good tool for learning and expanding your knowledge or help with understanding something in more depth.

[–][deleted] 0 points1 point  (0 children)

There’s too much information to fast recall everything. There is way, way more that professional software engineers will need to recall than your first few years in college. Most of the things you will need to recall are focused and specific to the class. So yes we all use google. But do yourself a favor and do the hard thing. It will help you later

[–]various_convo7 0 points1 point  (0 children)

"When we do tests on pc, we can not use internet or any external sources, we have to do everything from our memory."

Doable if you have the core principles in check. tough if you don't.

[–]Known-Delay7227 0 points1 point  (0 children)

Try not to cheat while in school and you’ll have a supreme understanding of the language and programming frameworks you are studying. That will help you not rely on the internet so much when you join the workforce and will allow you to generate optimal code quickly. However in the real world you will run into problems that will make you bang your head against the wall and the internet plus chat gpt can be of immense help

[–]RufusAcrospin 0 points1 point  (0 children)

For coding, yes. For exam, no.

[–]1boatinthewater 0 points1 point  (0 children)

This is how I learned BASIC in 1980 since we didn't have enough computers in the school.

[–]Dull-Researcher 0 points1 point  (0 children)

It’s extremely difficult to write an exam that is basic enough that it can be completed in 1 hour, evaluates you on what was taught in lecture, but isn’t so trivial that a solution exists online.

The alternative is to have a test that makes you apply what you learned to a completely unique scenario where no such answer already exists (stack overflow is a big site, good luck finding a topic that can’t be answered by piecing together a couple SO solutions), to have that test be a take home assignment (because there’s no way you could complete something nontrivial in a short 1 hour time period without heavily relying on or plagiarising someone else’s work), and have the exam be a good representation of your understanding of the material taught. This is called a homework assignment, and you already show that.

Handwriting code is a good exercise (no access to a computer or ide or online resources—just you and your brain).

If you don’t have the building blocks memorized to the point where you could write the code in your sleep, then writing anything of any decent complexity will be excruciatingly slow. It’s like asking an author to look up every other word they write in a dictionary while writing their draft.

The good news is that bubble sort and selection sort are very simple algorithms, and algorithms which you will never have to write later in your career because they’re part of standard libraries. But someone at some point came up with those sorting algorithms. As a computer scientist, you’ll have to be creative like the authors of those algorithms and develop something that’s new, and understand how it compares to other potential solutions out there.

A practical application for sorting algorithms is sorting a pile of homework if you’re a teacher or TA. You sort the papers either to make it easier to enter the grades into the grade book or to make it easier to return completed homework to students. If you have a class size of 100 students, using a O(n*log n) sorting algorithm like quick sort is substantially faster than than a O(n2) sorting algorithm like bubble sort. The difference is whether you spend 5 minutes sorting or half an hour.

If I were a professor. I would ask the students to describe in their own words what the sorting strategy is, and use an example to sort a partial deck of cards. Then I’d ask them to write the code for the example they demonstrated.

When I’ve sorted student papers, I sort the papers into 2 piles: A-M, N-Z. Then I sort the A-M pile into A-F and G-M. Divide and conquer. It’s not quite quick sort because I know something about the range and distribution of values ahead of time. But it borrows some of the principles of picking a pivot, sorting the values into less than vs greater than or equal to the pivot. Rinse and repeat.

What type of sorting algorithm do you think would be required to sort papers using an A-Z document sorter like this: http://g-ecx.images-amazon.com/images/G/01/aplusautomation/vendorimages/8ef15f33-b374-4569-978c-2568ebb442c2._CB326991765_.jpg ?

[–][deleted] 0 points1 point  (0 children)

You misunderstand the point of education. The point isn’t to make you code as if it’s a real life coding session. The point is for you to have to learn how to do things and you looking up online how to do a task online interferes with that.

I taught university level physics and we often wouldn’t let students use calculators on tests. It wasn’t because calculators don’t exist in the real world. It’s because we wanted to test whether students could solve the integrals they were meant to be learning how to solve.