Coding Best Practices With Examples | Code Review Best Practices

  Рет қаралды 53,201

codebasics

codebasics

Күн бұрын

Пікірлер: 51
@codebasics
@codebasics 2 жыл бұрын
Do you want to learn technology from me? Check codebasics.io/ for my affordable video courses.
@darshanabhuyan5896
@darshanabhuyan5896 2 жыл бұрын
This guy is literally taught me much more than my professors.. Thanks a lot
@Dakshita-cd4yo
@Dakshita-cd4yo 2 ай бұрын
1. Use the right data structure 2. Don’t use unnecessary variables 3. Write more compact code 4. Come up with a good variable names (avoid abbreviations) 5. Don’t over complicate your code 6. Don’t nest your code too much 7. Be consistent with your naming conventions (stick to either snake/camel case)
@soupnoodles
@soupnoodles 2 жыл бұрын
Excellent video, I rarely see videos covering the importance of best practices & efficiency, which is crucial for a slower programming language such as Python. 0:59 Regarding this, sets don't exactly implement the `append` method, instead, you could do a set comprehension like so: `unique_countries = {customer['country'] for customer in customers}` 6:11 This is true, Altho, the `even_squares` method would be better of being a generator object, since it is only being iterated over once per function call. It is more memory efficient & faster `even_squares = (i*i for i in input if i % 2 == 0)` Using tuple parenthesis creates a generator object Great video overall, the first time I'm seeing a video from this channel, makes me want to check out more :)
@FurbnMax
@FurbnMax 3 жыл бұрын
Awesome tutorial, will have my first code review during my application process in a few days and am currently preparing. Much apprecheated!
@codebasics
@codebasics 3 жыл бұрын
Glad it helped!
@NeedforSpeedGamesforpc
@NeedforSpeedGamesforpc 3 жыл бұрын
I loved the 1st one which is use of Sets! Its been so long i have been coding but always underestimated power of sets.
@raghuvardhansaripalli9636
@raghuvardhansaripalli9636 4 жыл бұрын
Thanks Brother and it really helps me during the interviews. This video helps every developer and Sr. management as well. Now a days this is a common question in all the interviews from developer to Senior Engineering managers level. God bless you. !!!
@codebasics
@codebasics 4 жыл бұрын
Great to hear raghu!
@jaleeluddin9223
@jaleeluddin9223 2 жыл бұрын
So glad I discovered this accidently! Really good stuff
@workflop4117
@workflop4117 4 жыл бұрын
Really good advices! Plus they are explained in detail! Many thanks.
@codebasics
@codebasics 4 жыл бұрын
Glad it was helpful!
@user-wr4yl7tx3w
@user-wr4yl7tx3w Жыл бұрын
wow, great to see more videos like this.
@terrabyte-techy
@terrabyte-techy Жыл бұрын
Excellent job. Thanks for the upload, it really helps.
@codebasics
@codebasics Жыл бұрын
Glad it helped!
@sumitbabel5415
@sumitbabel5415 3 жыл бұрын
Very well discussed and really practical, hats off dear
@codebasics
@codebasics 3 жыл бұрын
Glad you enjoyed it
@kitsurubami
@kitsurubami 2 жыл бұрын
what about for i in range(100): return condition_1 and condition_2 and condition_3 and condition_4 ?
@StyleTrick
@StyleTrick 4 жыл бұрын
Great content, keeping code simple =)
@codebasics
@codebasics 4 жыл бұрын
Always!
@jaleeluddin9223
@jaleeluddin9223 2 жыл бұрын
Good stuff..Do you have many other similar videos?
@pratikpawar05
@pratikpawar05 4 жыл бұрын
Sir plz complete the data structure series as soon as possible. Because it is helping me a lot to learn data structure in better way. Also thank you for being such a nice teacher ❤️😍
@codebasics
@codebasics 4 жыл бұрын
Sure pratik. I am going to upload a tutorial on queue data structure in next few days. Stay tuned.
@RiyaSharma-gm5om
@RiyaSharma-gm5om 3 жыл бұрын
Great video...just what I was looking for. thanks for clubbing all this in a video.
@codebasics
@codebasics 3 жыл бұрын
👍☺️
@tagorerahul
@tagorerahul 7 ай бұрын
Really good vedio on code review
@joelbrighton2819
@joelbrighton2819 Жыл бұрын
"Write compact code" (1:10) This is questionable advice. We should write code that meets functional/non-functional requirements but is easy to read. Do you want to spend 2 minutes trying to understand 1 line of code or 15 seconds understanding 5 lines of code? (This is actually discussed later in the video). "phone_info is not used in multiple places" (2:55) Correct, but it **is** used when stepping through code (which is generally a good idea). You can't see what's in phone_info if you return it directly. For the sake of one temporary variable you make debugging easier without having to re-write the code. The other advice is great!
@GameMakerRob
@GameMakerRob Жыл бұрын
This was pretty good info
@nmana9759
@nmana9759 4 жыл бұрын
Very good explanation! Thank you!
@codebasics
@codebasics 4 жыл бұрын
Glad you enjoyed it!
@mdjohir9996
@mdjohir9996 4 жыл бұрын
@@codebasicsyou
@Kingkiyan24
@Kingkiyan24 3 жыл бұрын
Awesome tutorial.. thank you so much it was very helpful
@codebasics
@codebasics 3 жыл бұрын
You're welcome!
@davidobber6788
@davidobber6788 2 жыл бұрын
Nice video, more or less this is written in the wonderful Clean Code (by Robert Martin). But sometimes I prefer to store the output of a function on a variable just for debugging purposes, or to store something on a temporary variable to avoid train wagons (i.e. multiple rows with getA().getB().get(C).setXXX(), I prefer to declare C c = getA().getB())
@codebasics
@codebasics 2 жыл бұрын
Got it, I also use the same technique to avoid train wagons.
@user-wc7em8kf9d
@user-wc7em8kf9d 4 жыл бұрын
Thanks. Superb content!!!
@codebasics
@codebasics 4 жыл бұрын
My pleasure!
@mahanirvaantantra
@mahanirvaantantra 3 жыл бұрын
I slightly disagree with the process_numbers function review. I would prefer list and dict compression, for they improve the performance of code. Please let me know if someone disagrees with me. Along with their explanation.
@joelbrighton2819
@joelbrighton2819 Жыл бұрын
My view... use whatever approach meets the performance requirements of the application and is understandable and readable by other Developers (including yourself in 6 months)! When considering making a performance related change always ask whether the benefits are _really_ needed by the end users (or whether you just want to make the application a little bit faster for no tangible user benefit). 🙂
@atulpatil2289
@atulpatil2289 3 жыл бұрын
Thank you sir... Sir, can you plz tell which resource or anything I can follow to improve my coding practices?....as I'm learning everything alone so don't have anyone to review my code.
@alxx736
@alxx736 4 жыл бұрын
Coding Best Practices vs Code Smell ? Which is the difference? Could you give me both definitions? Thanks
@pabloestrada9114
@pabloestrada9114 3 жыл бұрын
Gracias! Muy bueno!
@MadForCs16
@MadForCs16 4 жыл бұрын
very helpful. thank you.
@codebasics
@codebasics 4 жыл бұрын
Glad it was helpful!
@sauravadhikari8842
@sauravadhikari8842 2 жыл бұрын
10:03 you can do nothing in java without class and object
@akashbadgujar5825
@akashbadgujar5825 4 ай бұрын
What he meant is you can keep multiple methods in the same class. Why always create new classes when not needed. Using SOLID without understanding can be harmful.
@ashutoshpatra440
@ashutoshpatra440 4 жыл бұрын
Thank you sir.....
@codebasics
@codebasics 4 жыл бұрын
Most welcome
@savansanghavi7465
@savansanghavi7465 4 жыл бұрын
Now this was cool
@codebasics
@codebasics 4 жыл бұрын
I am happy this was helpful to you.
@bloodylyons
@bloodylyons 5 ай бұрын
Compact code does not always mean it is more readable
How to Do Code Reviews Like a Human
22:49
PyGotham 2018
Рет қаралды 43 М.
Tips to improve programming skills
10:00
codebasics
Рет қаралды 15 М.
Сестра обхитрила!
00:17
Victoria Portfolio
Рет қаралды 958 М.
How Strong Is Tape?
00:24
Stokes Twins
Рет қаралды 96 МЛН
1% vs 100% #beatbox #tiktok
01:10
BeatboxJCOP
Рет қаралды 67 МЛН
So Cute 🥰 who is better?
00:15
dednahype
Рет қаралды 19 МЛН
Dependency Injection, The Best Pattern
13:16
CodeAesthetic
Рет қаралды 899 М.
3 Tips To Write Clean Code (from an ex-Google software engineer)
17:12
Clément Mihailescu
Рет қаралды 198 М.
Junior Developer Sent Me Another PR For Review
15:44
Amigoscode
Рет қаралды 105 М.
Best practices for coding in .NET
8:06
Interview Happy
Рет қаралды 29 М.
Turning bad React code into senior React code
13:10
Cosden Solutions
Рет қаралды 94 М.
How Senior Programmers ACTUALLY Write Code
13:37
Thriving Technologist
Рет қаралды 1,6 МЛН
Code Review Best Practices
58:47
JetBrains
Рет қаралды 94 М.
Junior Developer Sent Me A PR For Review
17:26
Amigoscode
Рет қаралды 170 М.
Code reviews, styles and solutions with Software Engineer @sudocode
1:03:32
Master Pointers in C:  10X Your C Coding!
14:12
Dave's Garage
Рет қаралды 334 М.
Сестра обхитрила!
00:17
Victoria Portfolio
Рет қаралды 958 М.