Это видео недоступно.
Сожалеем об этом.
How to use var keyword in java - Brain Bytes
HTML-код
- Опубликовано: 16 май 2019
- Learn how to use var in Java!
Java now has a var keyword that lets you create new variables without specifying type. In this Brain Byte, learn how to use the var keyword in Java and also where you shouldn't use it.
Java Brains website: javabrains.io
#JavaBrains #BrainBytes #HowTo
Hey man, just wanted to say that your video series have helped me reached 6 figures! Thank you for making these videos. No doubt I will continue to use your videos as a valuable resource.
When did you start programming?
best explanation .. nothing new though .. this is always the case whenever we have a video from java brains
You produce or of the best technical content. love you , GOD bless you .
Amin
The introduction of this concept was -imho- a big mistake. Absolut superfluous.. But anyway, you described it absolut perfect!! Thanks for your video
When you said that using keyword var would break the 'Programming by Interface', I frowned :( I don't think I'm going to use var in my codes... Thanks for sharing!
As usual great explanation... Thanks for video.
Too smart explanation
a question:
var names = new ArrayList();
// which method will be called?
fancyMethod(names);
private void fancyMethod(List list) { ... }
// this one?
private void fancyMethod(ArrayList list) { ... }
Cesar Mora Java tries to use the most specific parameter list it can find.
If its Alist goes to alist method.
If its some other list like linked list then goes with parent.
I love the video, but I am not a fan of LVTI (Local Variable Type Inference). IMHO, it actually makes the code less readable and makes it more susceptible to misinterpretation bugs.
Thanks for sharing
Hello Kaushik, You really have a gift of teaching. If you don't mind, do you provide paid classes or you have some website where one can enroll/subscribe for his own TechStack, e.g Machine learning, data science etc.
great video
Interesting . Java is becoming cool day by day
i enjoy your tutorials, but do you have an introduction to Java for beginners?
Nice explanation. These features are already there in Scala.
Awesome Explanation!!!
Sir , please provide hadoop tutorial..
Thank you koushik for this great video!!!
Thanks for sharing this knowledge!
Java there is no ending. Can you please make videos on audit by jpa. Please thank you.
An even smarter move would be to learn from the wisdom of Go and include an operator to do in one shot without var. In Go, it's just "x := 10". Other than occasional projects for work, I use Go for most things. Once you learn Go, it's hard to heading back to Java
Go is bull crap
I can already see developers getting confused between initialization of new variable, and assigning to existing variable.
Digging a well for oneself is not called smart.
Clean and great explanation!!
Explained really well.
First session on Java 10 :) thanks
Very good explanation
Well explained sir.
I got the notification today 🙈
Good video nice explanation
as usual amazing ... you are ..
Can you help us with Data structures and algorithms...
thanks sir ....i want to ask a question..is all the E-Wallet companies like Paytm,paypal..are provide us just a database for storing our credits(money) ...how can i create my own small E-wallet in my springboot webapp pleasereply me thankyou..
thanks !
Sir, Reactive Programming please
I fail to understand why do people record with dark background for the IDE's. This really makes no sense to view the things clearly. While it may be a personal preference for the one who is recording but the letters/words gets grayed out in most of the cases on the dark background...
Sir what is bean in spring framework?
What editor is used in this video for the code?
Thanks
thank you!
Thanks!
Sir , please makes java course .
perfect
whats is best? the word "var" or especificed the data type?
using var is a big no go - bad practise. declare the variable as a specific type if possible.
Tq.. Sir...
Solarized IntelliJ?
which vs code theme is these?
What editor are you using?
Looks like JetBrains IntelliJ
I think it's Atom... not Intellij... I use Intellij it's not like that
I do not understand the "coding to interfaces" part @5:10
var in Java? I didn't know it was possible
It comes java 10
cool
What JDK version allows this?
Java 10
@@marcokapo96 I heard it later, but I keep my comment if somebody else had my doubt :)
Is the following code allowed :
var i=10;
i="some string" ;
In your mind, replace var with the type on the RHS and you'll have the answer. Which is no.
Java generics and Design pattern videos please :)
var is a disaster of a language change for Java. It will simply make code more unreadable and un-maintainable. Thank you for the presentation.
We love java without var keyword.But thanks a lot for video.😁
Nobody:
Java: lets introduce var.
Nah c# did first
Oh no no its a meme terminology. It means nobody asked for it
yok yokluk = null; :D
👀 In short Java is now becoming Scala , just like C++ has auto ..... noice 🤦🏽♂️ not sure which demographic Java is trying to apeal or please with this chNge 😅 .... nevermind, i guess it's time to update 👀 ny Java 8,
He had, no derivative yet! i = letter not -- any #!
So now Java, JavaScript and Swift all look the same.
Not helpful, just for the lazy ones….IMHO: it doesn‘t improve anything. And why is: var i = 10; int and not byte, long,….? Is that a definition of „var“?
What does java think it is, JAVA SCRIPT!!!
Bore off