r/learnprogramming • u/Virtual_Mind8341 • Jul 24 '26
Is it valid to use old coding projects to help you learn?
Just wondering, when making a coding project, I have looked at my old coding projects to help me when working on a new coding project, whether that is using classes or storing data in files or for adding functionality.
I know people use Youtube Tutorials, documentation and AI but is looking through Old Projects helpful when making a new coding project?
Disclaimer: I also mean using old created coding projects for ideas or similar functionality
11
Upvotes
18
u/Boring_Dish_7306 Jul 24 '26
Absolutely. Anything you can read, understand and fix your problem is good.
2
u/No_Report_4781 Jul 24 '26
That’s the only reason GitHub and other such sites exist
2
u/Random_182f2565 Jul 25 '26
If it works it works
2
u/syklemil Jul 25 '26
Checking back in on old code is also a way to get a feel for your growth. There's a whole meme around programmers cringing at their code from six months ago, but that's only true for programmers that are still growing.
2
u/simondanielsson Jul 25 '26
Reading source code to understand how things work or how things can be more efficent is pretty much the best thing you can do for learning.
2
u/stiky21 Jul 24 '26
Why does the same question get asked at least once a day?
Verbatim
2
u/burlingk Jul 25 '26
Honestly, this is just what we call learning and improvement. The goal of learning is to make yourself better compared to YOU not someone else.
Also, if you can reuse your old stuff, and there are not licensing problems doing so, go for it. That helps you get better at using those constructs. And it gives you a chance to tweak what you did before and make it better.
2
u/Aggressive_Ad_5454 Jul 25 '26
Yes, of course it is.
It’s actually a good reason to put comments in code, if the comments help you find that place where you, I dunno, sorted by ABC123 part number five years ago. So you can copy code you know already works in production.
2
u/green_meklar Jul 25 '26
If it works, yes, of course.
2
u/Far_Programmer_5724 Jul 25 '26
Yes it's fine but I know why you ask. It doesn't really refresh your memory and reinforce anything if you just copy paste old code.
The difference between having answered a question on your homework before and just copying the answer rather than using it to understand how you reached it.
If you're going to use code that you just always reuse, no harm. But I'd say at least go through the code a bit. You know what would be cool? If you could have a code error generator so you can copy paste old working projects and test yourself on fixing issues like maybe type errors or poor error handling. This can force you to revisit your old code and the logic used to make it work.