+ 20

How do YOU cheat at coding?

I know methods of making your life easier as a coder, like copy/pasting large chunks of repetitious code, adapting pre-existing open-source code, and using libraries. But I was wondering if y'all out there have any other little tricks up your sleeves for streamlining/facilitating the process.

2nd Aug 2018, 8:45 PM
Charlie Mitchell
Charlie Mitchell - avatar
30 ответов
+ 45
Copying/pasting large chunks of code doesn't make your life easier. It makes it even harder. I prefer to write functions to avoid duplicates. I also use debugger. It makes it easier to find bugs.
3rd Aug 2018, 6:55 AM
Igor Makarsky
Igor Makarsky - avatar
+ 21
I have a small book in which I write keywords and their uses for each language. It's good when you are forgetful like me. You can also do a quick recap of the things you have learnt using that for some examination if you are a student.
3rd Aug 2018, 8:09 AM
Zakaria Arzoo
Zakaria Arzoo - avatar
+ 13
I like the sound of that, Remigiusz Schoida. Great idea. I'll work on it. Thanks!
3rd Aug 2018, 2:33 AM
Charlie Mitchell
Charlie Mitchell - avatar
+ 12
George S Mulbah, Igor Makarsky, Zakaria Arzoo, Ethan, Muhammad Talha, Amy, Phil, and Oma Falk. Great tips everyone! Thank you so much. This is all very helpful information. 🤙
3rd Aug 2018, 8:52 PM
Charlie Mitchell
Charlie Mitchell - avatar
+ 11
whenever You "cheat" without thinking about it, You are basically diggin your own grave... i know that from experience. AVOID duplication, use composition, learn design patterns and... FRAMEWORKS. The best tip: "study for 10 minutes per day."
3rd Aug 2018, 9:05 PM
Jakub Dubański
Jakub Dubański - avatar
+ 10
Jakub Dubański, two questions. What do you mean by 'use composition', and by 'learn 10 minutes daily' do you mean try to study for about 10 minutes per day?
3rd Aug 2018, 9:47 PM
Charlie Mitchell
Charlie Mitchell - avatar
+ 9
Right on. Thanks for clarifying Jakub Dubański. Great advice!
3rd Aug 2018, 10:15 PM
Charlie Mitchell
Charlie Mitchell - avatar
+ 8
Sebastian Keßler use debugger for that. You will save time :)
4th Aug 2018, 12:33 PM
Jakub Dubański
Jakub Dubański - avatar
+ 7
U can't cheat on coding. Some advices: 1. Use a dark theme for the compilator, it's more easy for the eye to catch where the problem is when it's a very long code and you will not be tired so fast. 2. Comments in the code will help u, I didn't use them before even when my teacher told me but when I forgot smth, I used to delete some lines when I couldn't find where the mistakes were.
3rd Aug 2018, 1:49 PM
Amy
+ 6
Charlie Mitchell yes, study for 10 mins per day - good catch. Composition in (i.e) Java is really nice for saving time and code. Many people prefer inheritance, which (for me) creates code, that is not easy to maintain or adapt in the future.
3rd Aug 2018, 9:52 PM
Jakub Dubański
Jakub Dubański - avatar
+ 6
Charlie Mitchell sure, cheers! :)
3rd Aug 2018, 10:18 PM
Jakub Dubański
Jakub Dubański - avatar
+ 5
always make sure your code are clear and easy for yourself to understand always upgrade and make your IDE in the way that it help you make your coding easy and understandacble
3rd Aug 2018, 3:42 AM
George S Mulbah II
George S Mulbah II - avatar
+ 5
modular programing, or something like that, you can reuse some codes like the classics chess 8 queens problem, Hanoi tower, etc. Keep some parts of the code in "modular" like plugins can save time but if your code be exposed you need re-code all your life work for all customers. An example isn't programming example but can illustrate, the spectre and meltdown fail on Intel CPU's reusing the same project for 5-15 years and never get revised, it's most hard to repair because is hardware if was software easy to solve but reputations ins't so good to keep.
4th Aug 2018, 12:07 AM
zufil u
zufil u - avatar
+ 4
making my old programs gui is a cool practice, which is also fun. you should try it
2nd Aug 2018, 10:23 PM
inxanedev!
inxanedev! - avatar
3rd Aug 2018, 7:47 AM
Charlie Mitchell
Charlie Mitchell - avatar
+ 4
i made my own template. whenever i write a new p5js prog, i copy it to have all scripts. If I have the idea of working on particle systems, i have a working program as template. also for other themes. .
3rd Aug 2018, 8:20 PM
Oma Falk
Oma Falk - avatar
+ 4
Copying /pasting large chunks of code doesn't help to a coder in learning,it also makes them lazy . it also throw you in a trouble, also make your life even harder.
4th Aug 2018, 10:46 AM
Jaiklen Singh
+ 3
I'm very new to this, but I write things out by hand and what it does in order to help me retain the information.
3rd Aug 2018, 7:32 PM
Phil
+ 3
i just copy then hold and post
3rd Aug 2018, 11:00 PM
xxFreshMoneyxx
xxFreshMoneyxx - avatar
+ 3
When a Code returns a strange Output or a Loop won't break, then I implement a lot of print / cout instructions to see the Value of every Variable during the Programs runtime.
4th Aug 2018, 12:22 PM
Sebastian Keßler
Sebastian Keßler - avatar