I already have a long rant on how JavaTpoint sucks. This one is about Durgasoft.
Durgasoft offerst videos on Java and other programming topics. I will only comment on one video, but first I want to just show what the official website looks like:
The video I’m going to review is titled “Core Java with OCJP/SCJP : Language Fundamentals Part-1 || Java Identifiers and Reserved Words” and it was uploaded to YouTube on August 4th, 2015. It’s the first of 23 videos on “Core Java”.
Then I have a look at another video from some other series:
Difference between final, finally, finalize ?
As far as I know this is Sir Durga himself giving the lecture. In the Core Java series he wants to talk about identifiers, reserved words, data types, literals, arrays, types of variables, var-arg methods, main method, command line arguments, and Java coding standards. This video is about the first two topics.
For some reason compiling is not part of this and I don’t know if the students are expected to already know C/C++ or other languages.
Identifiers and Reserved Words
He uses the analogy of names. People have names, which are used to identify people. That’s ok, but it can lead to the misconception that variable names are somehow related to the name of the referenced object. That’s not the case:
var jack = new Person("Jill"); jack = new Person("Bob");
Compare this to actually using the “name” property to find some object:
List<People> people = data.getPeople(); var jack = people.stream().filter(p -> p.getName().equals("Jack")).findAny();
The example code he uses is fairly good to show examples of identifiers.
He then claims that only certain characters are allowed. That is true but he’s missing quite a lot of them. In Java you can use characters, such as ü, ñ, and γ, without any problems.
In a very impressive way he shows that identifiers can be crazy long.
This is now already over 20 minutes into the video and we don’t really know what identifiers are used for. We don’t know what variables or classes are.
He claims that there are 53 reserved words in Java, which was correct at the time.
But what’s the point of going through all these words, when the students have no idea what they are used for? How would anyone learn anything from this?
What was the goal of this first video? To know that identifiers are “names”? To memorise 53 reserved words?
Where are the exercises? What are the mentioned things, like variables, main, and String? I don’t see how a beginner would learn anything.
I didn’t find many errors in this video. But there isn’t that much information. He repeats everything five times, but doesn’t really say much. Don’t students already know that variables have names from maths class? Wouldn’t it make more sense to actually start programming?
final, finally, finalize
These three topics are not related at all. Just because “final” is in all three terms doesn’t mean it makes sense to look at them in one lecture.
The title is “Difference between final, finally, finalize ?” So you’d expect to get an answer in this video. But there is no “difference” as they are not related.
He claims that final variables become constant. That can be somewhat misleading. At least he correctly states in the slide that “we can’t perform re-assignment for that variable”.
Then he claims that you can’t override final methods. That’s true, but what about final static methods? He forgets those.
How he explains it, it seems as if you could only have a finally-block if there is also a catch-block. That’s not the case.
This video is from 2014, so try-with-resource was not a thing yet. But that’s the problem with videos. They are always outdated and can’t be easily fixed.
It’s true that finally us often used for clean up code. But he doesn’t explain what that is.
In this video he claims that finalize could be used to close database connections. That would be a very bad idea.
He also claims that once the GC sees an object that is due to be removed it will definitely do so. That’s not true. In the slide he even claims that it is “always invoked”, which is not true when the JVM stops.
Anyone who studied Java would know that finalize methods are to be avoided.
Some videos aren’t that bad
I’ve only looked at a few videos by Mr. Durga. Some aren’t that bad. For example the one on regular expressions. He says that a regular expression (RE) defined a group of strings. That’s actually a good definition. And he gives some examples. And he explains that there are several applications for this concept. I only watched parts of the first video of this series, but maybe it’s not that bad.
But then I saw him mentioning “anonymous arrays” in some other video. How would an array have a name? They are all “anonymous”.
I did find some errors in the videos that simply should not be there. Based on his statements on the finalize method I assume that he lacks experience. I estimate that I could find one error in each and every video of his. In my opinion that is too much, as most videos do not have a high density of information.
It’s still better than JavaTPoint, which is written by amateurs, who don’t even understand the basics. Somehow Mr. Durga knows weird details, like that you could compile
new int[-1];, but he does not understand that closing a database connection in a finalize method would be about the worst design possible.
There are many books that are better and you can always just work through the official tutorials by Oracle. They are always up to date and it mentions that there are alternatives to finalize.