10 Most Common Java Developer Mistakes

preview_player
Показать описание
In this video, we'll be discussing the top 10 most common mistakes that Java developers make and how to avoid them. As a Java developer, it's important to stay on top of your game and avoid these common pitfalls to ensure your code is efficient, effective, and bug-free.

So, whether you're new to Java development or a seasoned pro, this video is a must-watch. Don't let these common mistakes hold you back from writing high-quality, efficient code.

Tune in now to learn how to avoid these top 10 most common Java developer mistakes.

Don't Forget to
===========================================

⭐ Table Of Contents ⭐
===========================================
00:00 - Intro
00:21 - Deleting inside Loop
03:12 - Generics
05:08 - Equality
06:19 - If Statements
07:36 - Ternary If Statement
08:39 - Static
09:43 - Switch Statements
10:51 - Try with resources
12:15 - Excessive Garbage Allocation
13:09 - Nulls
14:36 - Libraries

🙊 Here are the goods for all my videos video 🙊

► Recommended Books
===========================================

► Computer and Monitor
===========================================

► Camera Gear
=============================================

► IDE & Tools I use for coding 💻 🎒
===========================================
- ITerm
- VsCode
- GoLand
- IntelliJ Ultimate
- Sublime

P.S
===========================================

❤️ Thanks for watching
Рекомендации по теме
Комментарии
Автор

I'm a senior software engineer and I didn't need to listen to this video, but I did. I positioned myself as a beginner and I found your video really interesting. The method of iterative corrections (in the "bool == true" example) is awesome. People learn and retain better this way (from my experience).

I would like to express an amelioration you could do: give reasons why this or that is better and I also would tell in which circumstance. Example: In the ternary example, I do prefer one liner too, but only if it is short. And moreover, why there was a mistake (because, in fact, in terms of code execution, there is no difference at all)? (This is not a question to answer here, I already have the answer).

That's it! Great video!

masterdjon
Автор

Since java 14 (i think) we can write switch statement using ->. for example:
switch (caseIndex) {
case 0 -> System.out.println("zero")
case 1 -> System.out.println("one")
default -> System.out.println("sth")
}
and using that we don't have to add break statement

MrMineadrian
Автор

Good Information! The only thing I think is important to mention additionally is that in the first example, you should also check for null values to avoid a NullPointerException. In general I think just comparing Strings with equals without considering null values is one of the most common beginner mistakes!

zazahead
Автор

I am very new programmer, I took Amigoscode Java Master Class and I can proudly say that I am not doing not even one of these mistakes because the course taught we well. Thanks buddy! Now I see how the powerful your teaching really is

Apopjak
Автор

thanks for the info. But I think it would have been much easier to use the "new switch expression" available since java 12, if we used that our code would have been
switch (caseIndex) {
case 0 -> sout("zero");
case 1 -> sout("one");
case 2 -> sout("two");
case 3 -> sout("three");
default -> sout("default")
}

ilhomjonaxmatov
Автор

5 Months ago, I started studying cs in university, i still have no clue about coding... (lol)
Afters seeing your video, i got smarter. Nice teaching!

muoiomanuel
Автор

im currently switching back to java (from php) and videos like this are a great help. forgot a ton of stuff

GuRuGeorge
Автор

i started learning java 5 months ago and just found your channel

hiro
Автор

12:09
you can write do-while loop
instead the while loop to make it good concepts of loops

zip
Автор

4:45 Worth stressing how important it is to use interfaces. This is a very simple example, but if it’s being passed around your codebase as the concrete implementation, that’s a lot of places you’ll need to change if you decide to use a different implementation… The same is true for when you use third party libraries, database etc. You will usually want some interface to that code

meostyles
Автор

Many things looks similar to JavaScript, I'm thinking of learning Java after mastering JavaScript

developer_hadi
Автор

Very helpful in fact at the right time against cosc211 Java OOP exams we'll have tomorrow.

isahbala
Автор

Really amazing, man! As junior developer I really want to thank you for the tips.

GianfrancoTerrazzano
Автор

Hey @Amigoscode, I have been watching your channel for a while and I think it's the best Java programming channel on YouTube. Keep up the hard work and wish you all the best.

flaviu-vanca
Автор

Man i just love watching ur videos, learnt a lot of standards from ur code review videos. Currently i am planning to change jobs and quite afraid that i am not up to the level. :(. Keep posting these videos, i learn a lot from you, Thank u for everythiing

gokuls
Автор

As a code reviewer, the mistakes I see most often every day are from developers who don't understand Boolean algebra, creating code like "if (value == true) return true", and the most common is using return null instead of optional.

rnt
Автор

Can you please make a video about event-driven architecture with Spring Boot and Axion Framework please ? and thank you

michelchaghoury
Автор

Thanks for the video and Ramadan Mubarak, brother!

Maged_Mohsen
Автор

I think I could consider myself as a senior developer because whatever you explained in this video i know all of these.

praveens
Автор

Good format mate, knew some but certainly not all... fun to follow along.

ITZollx