Flutter Tutorial for Beginners #3 - Dart Primer

Поділитися
Вставка
  • Опубліковано 14 жов 2024
  • Hey gang, in this Flutter tutorial I'll give you a quick primer to the Dart language, which is what we'll be using t create our Flutter apps. We'll look at variables, functions, lists and classes. You can practise dart on Dart Pad here - dartpad.dartla...
    ----------------------------------------
    🐱‍💻 🐱‍💻 Course Links:
    Course files - github.com/iam...
    Android Studio - developer.andr...
    Git - git-scm.com/do...
    Flutter Installation - flutter.dev/do...
    🐱‍💻 🐱‍💻 Other Related Courses:
    Modern JavaScript Tutorial - www.udemy.com/...

КОМЕНТАРІ • 649

  • @KaranSingh-ty5xr
    @KaranSingh-ty5xr 4 роки тому +386

    0:00 Disclaimer
    1:38 Types
    5:58 Functions
    9:45 Comments and Arrow Functions
    10:43 List (like arrays)
    13:05 Typed Lists
    14:15 Classes
    21:40 Inheritance

  • @derencewalk
    @derencewalk 5 років тому +813

    This is the clearest demonstration of classes and constructors in all of recorded history.

  • @cooperu2194
    @cooperu2194 3 роки тому +281

    For anyone who is confused around 21:30. They added a new keyword "late" in 2.12 which is now necessary to put before String and int under class User. Should look like this:
    late String username;
    late int age;
    Late means that the variable is not called until it is referenced for the first time

  • @sarerusoldone
    @sarerusoldone 4 роки тому +286

    Net Ninja: declares that he won't explain the basics of programming
    Also Net Ninja: explains the basics of programming

  • @wizzl8513
    @wizzl8513 4 роки тому +207

    The fact that you put out this level of quality content for free is mind-boggling to me

    • @cenwesi1
      @cenwesi1 4 роки тому +2

      I have to agree with the poster... I recalled learning about classes back in 1995 and you explained it like i learned it back then

  • @hatimus
    @hatimus 5 років тому +141

    The best demonstration of classes and constructors on youtube. And the best accent, too.
    Please keep the good work on.

  • @srajankishorgupta1011
    @srajankishorgupta1011 4 роки тому +59

    I've been a c++ and java guy for two years, and it feels like that dart is just a baby of both. And the way you explained it, felt damn easy.

  • @AfricanModernFamily
    @AfricanModernFamily 4 роки тому +54

    The video is 27 minutes but feel likes its omly 2 minutes ...you are really a ninja in tech...awesome class explanation

  • @Redomic
    @Redomic 3 роки тому +136

    Flutter added a whole lotta new stuff with 2.0 including Null safety that doesn't let you initialize types with a null value. So if you wanna get rid of that, uncheck the Null safety feature in Dartpad in the bottom-left

  • @willglasse6520
    @willglasse6520 5 років тому +34

    You are extremely eloquent, my friend! Clear and concise. Very excited to see where this course goes!

    • @NetNinja
      @NetNinja  5 років тому +1

      Thanks Will :)

  • @Huy-ed2re
    @Huy-ed2re 4 роки тому +3

    A quick rundown on Dart basic types, classes, constructor functions and even inheritance. What a gold mine of knowledge inside a 30 min long video! Best Dart primer I've seen among all internet content, ever!

  • @dagi3715
    @dagi3715 3 роки тому +4

    I've never seen anyone explaining about classes, method and inheritance this much clearly. 👏👏👏👏

  • @raymondmichael4987
    @raymondmichael4987 5 років тому +50

    Dude, this intro was loaded, I understood very well mixing my arduino-c++ and JS coding skills,
    Again thanks this series.
    Greetings from Tanzania 🇹🇿

    • @NetNinja
      @NetNinja  5 років тому +3

      Thanks Raymon :D

    • @HK-sw3vi
      @HK-sw3vi 4 роки тому +1

      dart is so much like c++

    • @mohamedmusamustafa3324
      @mohamedmusamustafa3324 4 роки тому

      @@HK-sw3vi and C#

    • @juliusbarde5332
      @juliusbarde5332 4 роки тому

      More like java

    • @jayanthbit2051
      @jayanthbit2051 4 роки тому

      @@mohamedmusamustafa3324 it feels like a mixture of C++ and python to me. Similar syntax to C++ yet easy to learn

  • @SandrMusicTV
    @SandrMusicTV 2 роки тому +24

    I think this video was before the 'late' keyword was released in dart 2.1. That is why I keep having errors in the class scope. In Dart, we use the late keyword to declare variables that will be initialised later. If you're having errors in 21:09 , just add 'late' before your two variables in the class scope. Thanks!

    • @Suamt
      @Suamt Рік тому +3

      thank you... was driving crazy

  • @SreyRc
    @SreyRc 4 роки тому +5

    In all my years of programming, this 27 min video finally clarified the concepts of classes and objects for me. You're the real Ghost of Tsushima when it comes to programming and explaining things.

    • @Hruslow
      @Hruslow 3 роки тому +2

      How did you manage to program without understanding these basic concepts?

    • @qudusogg5897
      @qudusogg5897 2 роки тому

      Can you please help me I just want to start programming 😢👋

  • @kirina6268
    @kirina6268 3 роки тому +1

    Definitely the clearest explanation about the basics of programming, even you are not into Flutter you can still watch this video to understand the logic of programming.

  • @dojafoja
    @dojafoja 3 роки тому +2

    These videos are great. I come from 10+ years of writing Python and these videos are helping me understand syntax differences between Python and Dart. I feel like Im finally starting to have the ability to read Dart code without feeling lost in the syntax.

  • @ruchibajracharya8294
    @ruchibajracharya8294 8 місяців тому +1

    you simplified the class and object topic so smoothly and so easity. great tutorial

  • @CptTurk81
    @CptTurk81 4 місяці тому +1

    omg you've just explained what classes are to me in the most simplest way! I'm not a developer and found it so difficult to understand classes in Python and programming in general. Thank you so much :) best explanation ever. Im going through this dart/flutter playlist and Im loving it so far. Yes Im about 4 years late to the party :D

    • @NetNinja
      @NetNinja  4 місяці тому +1

      Glad it was helpful! :) thanks for watching, and don't forget to check out the latest Flutter crash course: ua-cam.com/play/PL4cUxeGkcC9giLVXCHSQmWqlHc9BLXdVx.html

  • @nithinjoseph7927
    @nithinjoseph7927 4 роки тому

    You are explaining in the simplest form .I dont think any one will be able to simplify than this.Even a person doesnt know basics of programming can understand .Thank you so much.

  • @5rob791
    @5rob791 7 місяців тому

    I know this is 4 years old, but just wanted to say that I've brute forced learning java and C# for Unity for a few years and no tutorial I've seen has explained the basics of coding as well as you have in this video. Things I've been told, like just writing like Void or adding to define the data type of a List, I've always just nodded as others have skipped over explaining what they actually do. This video alone has just made so many things I've memorized as necessary, but never understood, just click in my brain with comprehension. Thanks so much for making this series. Excited for the rest! Cheers!

  • @whitesites
    @whitesites Місяць тому

    Best Coding Tutorial I have ever watched, and one of the few that is spoken in clear english!

    • @NetNinja
      @NetNinja  Місяць тому

      Glad it was helpful! :) thanks for watching

  • @KofaOne
    @KofaOne 2 місяці тому

    You are the BEST programming basics teacher. I've literally watched Udemy courses, watched dozens of Kotlin and C tutorials, and I thought programming just wasn't for me. Until you explained instancing classes and this. parameter in 6 minutes, perfectly.

    • @NetNinja
      @NetNinja  2 місяці тому

      That means so much :) thanks Kofa!

  • @devendrasolunke4619
    @devendrasolunke4619 3 роки тому

    This is first foreigner ....who is teaching like everyone can understand...🙌🏼 Thanks sir...

  • @masamunekozuki5012
    @masamunekozuki5012 7 місяців тому

    i started in ionic and its a hardcore learning curve on every tutorial ive watched. while this one is so step by step THANKS A LOT.

  • @seppl330
    @seppl330 4 роки тому +3

    I'm kind of a beginner to programming, but this Explanation made me (maybe the first time) REALLY understand classes, functions and constructors. Thank you very much!

  • @siiir7396
    @siiir7396 4 роки тому +14

    im gonna save you some time:
    0:00 Disclaimer
    1:38 Types
    5:58 Functions
    9:45 Comments and Arrow Functions
    10:43 List (like arrays)
    13:05 Typed Lists
    14:15 Classes
    21:40 Inheritance

  • @steveshemandayambaje287
    @steveshemandayambaje287 2 роки тому

    This tutorial is the clearest and simplest way of learning Dart! I came here with no prior knowledge of DART whatsoever, and I have been left with a complete understanding of all its core concepts! It's amazing! Props to The Net Ninja!

    • @NetNinja
      @NetNinja  2 роки тому

      That's great to hear Steve :) glad it was helpful! Thanks

  • @rakeshpk4991
    @rakeshpk4991 2 роки тому

    Thank you very much. I started React with your videos. Now am almost an expert in React. Built a project using React and Relay Modern. Now I am starting my first steps in Flutter with you. Thanks again!

  • @ianeyansky5635
    @ianeyansky5635 4 роки тому +3

    This is awesome. I believe this should be a standalone dart crash course. Really helpful.

  • @akira7ink
    @akira7ink 5 років тому +14

    Really, that’s the first time ever I really, REALLY understood classes. Thanks a lot

    • @NetNinja
      @NetNinja  5 років тому

      Awesome! Thanks for watching :)

  • @hedgehox3160
    @hedgehox3160 5 років тому +8

    You are amazing, I just discovered your channel and I am really excited to see how well are you explaining everything about Flutter in your video tutorials, Big thanks from me!

    • @NetNinja
      @NetNinja  5 років тому +1

      Thanks Michael :)

  • @meeseeks1489
    @meeseeks1489 3 роки тому +1

    i love the way he is providing all of this for free, when he could actually make us pay for such a quality teching! thankyou so much

  • @cswithabdullah2638
    @cswithabdullah2638 3 роки тому +1

    Cleared most of Classes and Objects concepts in just few minutes. JazakAllah! Nice content!

  • @antoniofuller2331
    @antoniofuller2331 4 місяці тому

    My flutter installation was successful, and all the checks passed. Now I can finally follow this tutorial and code 🎉

  • @QuasiTheSecond
    @QuasiTheSecond 3 роки тому +80

    Going through this now in 2021 and noticing for part 3 that the User Method Function doesn't work unless you make the String and int nullable by adding a ? after String and int. Apparently this is because Dart 2.12 introduced Null Safety. Figured I'd comment since I ran into this problem and this was how I solved it to get the same results.

    • @moroniafrifa614
      @moroniafrifa614 3 роки тому +17

      You can also add late before string and in as in: "late String username". "Late int age"

    • @NotePortal
      @NotePortal 3 роки тому +3

      OMG TYSM, I WAS TRYING TO FIX THIS FOR AN HOUR!

    • @earthbound3916
      @earthbound3916 3 роки тому

      thank you!

    • @robotmossadek
      @robotmossadek 2 роки тому

      omfg thank youuu

    • @parthjamdade4430
      @parthjamdade4430 2 роки тому

      @@moroniafrifa614 tysm man

  • @algeriennesaffaires7017
    @algeriennesaffaires7017 4 роки тому

    i studied with Udacity for 9 months and they drove me crazy till today i didn't have a clear understanding of classes, now its my first time to be able to understand classes and constructors, Sir you are a master, my Allah Bless you, all your courses are the best thing i discovered in the web, cant thank you enough.

    • @NetNinja
      @NetNinja  4 роки тому +1

      Thanks so much :)

  • @vels7181
    @vels7181 4 роки тому +6

    Timeline index:
    1:06 Dart Pad
    2:10 Variables
    5:11 Dynamic variables
    6:00 Functions
    10:41 List
    14:18 Class
    19:03 Constructor
    21:34 Inheritance

  • @joshholder359
    @joshholder359 3 роки тому +4

    Great video. The one thing I'd say is that it's slightly confusing to use Super in the name of the inherited class, because it made it seem like the "super" method was one that was specific/related to SuperUser, not a method which is used in all of Dart

  • @Pygorable
    @Pygorable 2 роки тому

    This helped me so much not only with learning to use flutter, but also with my understanding of object oriented programming in general. Thank you!

  • @funnymccloud
    @funnymccloud 4 роки тому

    You are AMAZING!
    They way you teach basics of classes is simply PERFECT!

  • @dipinsonwani4029
    @dipinsonwani4029 4 роки тому +3

    The best and the simplistic tutorial I have ever come across. Thanks a lot!

  • @koubeen16
    @koubeen16 Рік тому

    I'm here to say I've never understood classes and constructors until now ! i had that aaaaah moment when everything becomes clear ! thank you !

    • @NetNinja
      @NetNinja  Рік тому +1

      That's great to hear Koubeen :) thanks for watching!

  • @roshansourav
    @roshansourav 4 роки тому

    the way of EXPLAINING is very-very cool, awesome. Precise and to-the-point. Loving it.

  • @calebmbugua745
    @calebmbugua745 4 роки тому +1

    Much Love from Kenya..Its a great Joy to find your tutorials.

  • @microdavid7098
    @microdavid7098 Рік тому

    it's kind of beautiful how intuitive this is

  • @xxmahir3000xx
    @xxmahir3000xx 3 роки тому

    You summarized two months of Object Oriented Programming at my college in one video. Thank you

  • @shoaibahmad6910
    @shoaibahmad6910 5 років тому

    I just can't believe that you will start this series. I'm expecting a fully functional app after this beginner series. Thanks for quality content

  • @mattprado21
    @mattprado21 4 роки тому

    Very clear tutorial, I will remember how you explain classes and constructor and use it when someone wants to understand those topics

  • @Contemelia
    @Contemelia 4 роки тому

    The amount of detail you put in a short video... Man thas dope...

  • @mesharibuhadi1437
    @mesharibuhadi1437 3 роки тому +1

    i had to pause this video to take a moment to write this comment, great stuff man thank you very much for providing such premium content for free.

  • @Cho1279624
    @Cho1279624 5 років тому +1

    Hey, Shaun! You are already a legendary net-ninja. Thanks for you being around us.

  • @shupesmerga4694
    @shupesmerga4694 4 роки тому

    OMG! Ahh... The nostalgia.
    Feels so good to see c++.
    The first proglang i took and fell in love right away.

  • @iforce2d
    @iforce2d 2 роки тому

    This is the first I've seen of Dart and I'm liking it a lot so far. It's like the perfect blend of C++ and JavaScript. Regular JavaScript classes (uhh... I mean, functions?) are confusing as hell.

  • @zurggie
    @zurggie 4 роки тому

    Omg.. I've been struggling to understand class in Javascript and php. This is the first time it all make sense. Thanks a lot!

  • @sergiowmuller
    @sergiowmuller 2 роки тому

    the simplest and the best dart class video ever. Great!

  • @prankcial4187
    @prankcial4187 4 роки тому

    For the first time, I understood class completely.
    Thanks for this free tutorial. :)

  • @squid84202
    @squid84202 4 роки тому

    I just want to reiterate what everyone else is saying and tell you that you are very good at explaining classes and constructors. I am learning Dart because I want to make an Android app, but even when I was learning C++ in class my teacher never did as good a job as you in explaining classes, objects and constructors.

  • @ReinOwader
    @ReinOwader 4 роки тому

    Everybody's comments here how they understood classes is discouraging to me because I have tried to learn them before in Python, and didn't understand then, and sadly I didn't understand now either, even though it was very clearly explained. It makes me feel stupid :( But no problem. I probably have to get Class concepts from books and take it in my own pace. I get it eventually.
    Your tutorials are probably best I have seen. Clear, fast, high quality screen capture and audio. Something that is hard to get even from commercial sites like Udemy. Thumbs Up.

  • @mollevi99
    @mollevi99 9 місяців тому +1

    Naming the inheriting class SuperUser might be confusing to those who are unfamiliar with the super(params) concept. Therefore this: you can make
    class Admin extends User{
    ...members
    /*and still have to use*/
    Admin(...):super(params)...;
    }
    I hope this was helpful :)

  • @witchestify
    @witchestify 4 роки тому

    2 YEARS IN MAJORING IN INFORMATICS ENGINEERING DONT KNOW WHAT TO DO WITH CONSTRUCTOR. THIS 30 MINUTE VIDEO MAKE IT CLEAR... damnnn

  • @yashjain2885
    @yashjain2885 4 роки тому +1

    Thank you so much for such clean and clear tutorial over Dart. Really Appreciated.

  • @coffeeupnorth1398
    @coffeeupnorth1398 5 років тому +13

    I love watching ads, specially if the content is this good!

    • @darshandayal8419
      @darshandayal8419 4 роки тому

      Download Opera Gx browser, u can watch the UA-cam without ads

  • @the-aditya-raj
    @the-aditya-raj 4 роки тому +1

    In my opinion, I believe the User class should be called SuperUser and vice versa. Anyways, it's the fantastic and clearest coding tutorial I ever saw about classes on UA-cam.
    Keep it up, man! Your Channel rocks.
    Love from India 💖

  • @tibuwi7059
    @tibuwi7059 4 роки тому +1

    Awesome explanation-skills! I am not new to programming, but this right there was without any doubt the cleanest explanation of this topic. I realised the comment section agrees on that

  • @kamal-ahmed
    @kamal-ahmed 5 років тому +1

    Excellent tutorial. I just learned dart basic in just 30 mins. thank you very much for this awesome tutorial.❤️

  • @venkataramananrajendran3525
    @venkataramananrajendran3525 4 роки тому

    You are too good dude...... Thanks a lot!!!!!! keep helping people like this... I learnt React from You... React Native from You.... Now Flutter..... You're my guru dude.

  • @anuradhapathirana12
    @anuradhapathirana12 4 роки тому

    i have never seen a teacher like you. thank you. wow wow wow

  • @Kliamframe
    @Kliamframe 3 роки тому +1

    This is one of the best "Learn how to code" tutorials I've seen,

  • @profarvind
    @profarvind 3 роки тому

    You are an excellent teacher. You should be teaching in universities across the world.

  • @raymkfc
    @raymkfc 3 місяці тому +1

    Before watching this video, I feel like dart is quite complicated unlike Python, although I'm just a beginner in programming. I've watched a few videos, and I finally come to your channel. You are different! You used powerpoint presentation, and you used 'chun-li', these details make a huge difference in the view of the audience.

    • @NetNinja
      @NetNinja  3 місяці тому

      Great to hear! :) glad you enjoyed it.

    • @MaazKhan-nj3nf
      @MaazKhan-nj3nf 2 місяці тому +1

      ​@@NetNinjait's been 4 years since you posted this tutorial. Are all the concepts taught in this tutorial still applicable today??

  • @FunGuardian
    @FunGuardian 4 роки тому

    less than 30 minute, very clear,
    it's gold

  • @TheNerdyDev
    @TheNerdyDev 5 років тому

    Just started to learn Flutter, for a project. Super awesome content ! Top notch in each and every aspect of what a quality content should be. Thanks for the Series, Ninja !!

  • @RandomShowerThoughts
    @RandomShowerThoughts 2 роки тому

    easily the best series I've seen on flutter and dart, wow

    • @qudusogg5897
      @qudusogg5897 2 роки тому

      Hey please can we be friends I need someone to teach me this

  • @raghavkashyap324
    @raghavkashyap324 3 роки тому

    hearty thanks from me for explaining about flutter . It is helping me realise my goal of pursuing a carees relate to computer science and also thank you so very much for providing this quality content for free

  • @shayanabdurrehman7091
    @shayanabdurrehman7091 2 роки тому

    I just subscribed to your channel at "999k" and it turned to "1M" right after. Congratulations!

  • @aliasgar.burhani1099
    @aliasgar.burhani1099 3 роки тому

    Your accent makes it easy to understand for the people all around the world

  • @eliasdargham
    @eliasdargham 4 роки тому +1

    I know it's not an OOP tutorial, but it's kind of a pet peeve of mine to see object classes that have methods that call print()...
    Other than that everything is perfectly explained. You're the best...

  • @sushantpoudel651
    @sushantpoudel651 2 роки тому

    Best explanation i saw so far on programming..❤️ Love from nepal.

  • @neurosciencenerds3165
    @neurosciencenerds3165 3 роки тому

    This is the most amazing intro to a course I've ever been in

  • @hammad2147
    @hammad2147 4 роки тому

    i was never able to understand the role of constructor before . thank u , u r the best ......... i m in ur debt

  • @NagabhushanBaddi
    @NagabhushanBaddi 4 роки тому

    Damn! Dart is really easy! Nice Explanation! I recently went through your TypeScript and framer-motion tutorials, loved both of them!

  • @NahidAnam
    @NahidAnam 3 роки тому

    I never thought Dart is so easy. i just finished learning in this single video.. Thanks & lot & All praise is due to Allah.

  • @princevegeta7921
    @princevegeta7921 4 роки тому +1

    This is just C++ programming in C syntax. Great explanation.

  • @blouberguy4647
    @blouberguy4647 Рік тому

    thank you so much for this even tho you said that you need a basic understanding of classes you still did explained it really well and i know understand how to use classes !

  • @ndumisothembalakhengcobo4172
    @ndumisothembalakhengcobo4172 3 роки тому +1

    Best Flutter Tut in UA-cam by far. Loving every second of it

  • @shahriyarhussain3931
    @shahriyarhussain3931 4 роки тому

    If you learn dart after learning Java properly, not only you will say this is the best and easiest video explaining DART but also you will say how easy this language is compared to Java.

  • @lukasjacobs2358
    @lukasjacobs2358 4 роки тому +2

    Nice introduction overall, but I had somehow expected this to be a dart primer for people who know about programming after I watched the previous video. I haven't thought this long about "void" for at least 10 years :D

  • @hydragons
    @hydragons 4 роки тому

    Watching this at 2.5x because it is quite similar to java. Very nice refresher.

  • @abdulrahmanmaaz683
    @abdulrahmanmaaz683 5 років тому

    I rarely comment on videos, but your explanation is too good to not thank for it.
    Thanks for your effort

    • @NetNinja
      @NetNinja  5 років тому

      Thanks for your feedback :) really glad you are enjoying the tuts :)

  • @unomaash9656
    @unomaash9656 4 роки тому +2

    wow, honestly amazing video, managed to cover the first year of uni in 30 mins xD

  • @anujmore7547
    @anujmore7547 4 роки тому

    Perfect explanation of all the concepts that I was looking for flutter.
    Good Job Man

  • @adeyemiadeshina3988
    @adeyemiadeshina3988 4 роки тому

    This is the overview of Dart in 27 minutes video. Thank you!

  • @HappyHorge
    @HappyHorge 4 роки тому

    Hi Shaun!
    Something that might be misunderstood here with the SuperUser class, is that it is a sub class and not a superclass, though I don't think you stated that it was either. Next time it would be smart just to state which role the classes have when using inheritance, which is important when it comes to explaining OOP.
    Anyway, good explanation of the other concepts of OOP with a sprinkle of arrow functions in Dart :)

  • @profmo
    @profmo Рік тому

    This is so good, I am learning just by following the audio. Superb!

    • @NetNinja
      @NetNinja  Рік тому

      Great to hear, thanks Mo!

  • @petercourt
    @petercourt 4 роки тому

    Fantastic run through for programmers who need a brush up!

  • @Rick-sf2cz
    @Rick-sf2cz 5 років тому +3

    This is gonna be an amazing series thank you so much

  • @TechFriendly
    @TechFriendly 3 роки тому

    I understood all the concepts easily. Amazing video.

  • @JamesZkey
    @JamesZkey 4 роки тому

    Very well described use of the extend. Thank you.

  • @anikrahmanassaianjack
    @anikrahmanassaianjack Рік тому

    Excellent video.Very necesssary elemetns explained before starting flutter

    • @NetNinja
      @NetNinja  Рік тому

      Glad it was helpful! :)