Rust First Impressions

Поділитися
Вставка
  • Опубліковано 23 кві 2024
  • A quick look at the Rust programming language.
    💬 Topics:
    - What is Rust?
    - Advantages of Rust;
    - Rust Macros;
    - Immutability in Rust;
    - Rust code examples;
    - Ownership and Borrowing;
    - Rust crash course;
    🥇 Become a Member - / @awesome-coding
    ✉️ Join the Newsletter - newsletter.awesome.club/
    📖 Blog Article - www.awesome.club/blog/2024/ru...

КОМЕНТАРІ • 114

  • @EduardKaresli
    @EduardKaresli 2 місяці тому +55

    Being a former C++ developer myself really helps learning Rust. It cannot be more complicated than C++ 😂😂😂

    • @awesome-coding
      @awesome-coding  2 місяці тому +20

      That might be the only advantage of C++ - it makes everything else feel reall easy 😅

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

      @@awesome-coding C++ was a pain in the back, I programmed in it for 15+ years and everything was a problem, setup, libraries, the horrible make system and salaries. So I moved to JavaScript/TypeScript, but still I think any CompSci graduate needs a low-level language under their belt and Rust looks like a great candidate for the next 15-20 years.

    • @trappedcat3615
      @trappedcat3615 2 місяці тому +3

      I hear Haskell is another helper

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

      Just give it some time, and we will see

    • @JR-hb6jr
      @JR-hb6jr 2 місяці тому +2

      As a self taught front end web dev, Learning rust feel like I only have a single brain cell. Has been reading the book and watching let's get rusty videos and trying it out. It is very very hard. But I won't stop learning.

  • @heyjitendra
    @heyjitendra 2 місяці тому +28

    As a JavaScript developer this just fries my brain.

    • @awesome-coding
      @awesome-coding  2 місяці тому +20

      :)) Give it time!
      In all seriousness, one of the best things I did in my career is getting out of my comfort zone and learn concepts from different languages (this is what I'm trying to do with these videos as well). It's hard at first, but you'll gain a lot by learning how different languages are doing different things.

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

      +1 😅

    • @heyjitendra
      @heyjitendra 2 місяці тому +1

      @@awesome-coding yea I am learning Go. My college project is in go

    • @awesome-coding
      @awesome-coding  2 місяці тому +3

      @@heyjitendra Did you see my Go introduction video? :D
      ua-cam.com/video/E7pxGyEcPNI/v-deo.htmlsi=4uwMFklp2sSW9i40

    • @heyjitendra
      @heyjitendra 2 місяці тому +1

      @@awesome-coding yes awesome video :)

  • @MagicNumberArg
    @MagicNumberArg 2 місяці тому +10

    In Rust we have learned all the lessons of last 40 years, it's like C, but where writing a web service isn't much harder compared to modern GCed languages.

  • @fagnersales532
    @fagnersales532 2 місяці тому +9

    It would be nice to have a descriptive title that tells the video is part of the series. Would love to watch more.

    • @awesome-coding
      @awesome-coding  2 місяці тому

      Thank you for your suggestion! I'll try to make some changes :D

  • @TechBuddy_
    @TechBuddy_ 2 місяці тому +12

    rust mentioned let's goooooooo 🔥

    • @awesome-coding
      @awesome-coding  2 місяці тому

      Now I just have to wait for the hundreds of thousands of views 😅

  • @seasong7655
    @seasong7655 2 місяці тому +4

    I felt very unproductive in Rust and quickly went back to python for my projects. There's a lot of extra steps involved like catering to the borrow checker, lifetimes or chosing the correct string type. It's a lot of additional typing and doing other work instead of actually solving the problem at hand.

    • @awesome-coding
      @awesome-coding  2 місяці тому

      Fair points.

    • @savagemode2150
      @savagemode2150 2 місяці тому +6

      I found myself in the same spot switching from rust to golang over and over until rust suddenly clicked on me, then I ditched go and commited to rust, that was a year ago, I now feel just as (probably more) productive in rust as I was in go.. the bad part is that I got so used to rust that I now struggle to code in any other language that don’t provide so many guardrails like rust does

    • @savagemode2150
      @savagemode2150 2 місяці тому +1

      Plus rust really improved my cs knowledge, like understanding cpu and memory efficiency concepts and bad practices

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

      @@savagemode2150 Must give it a go also, are you using Rust in your day job?

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

      That's probably because Rust is primarily meant for low-level programming, while Python is the extreme exact opposite

  • @porcupinetree-bb3zg
    @porcupinetree-bb3zg 2 місяці тому +4

    make a video on the axum framework. i built a similar service to mailchimp with it. you could also include sqlx which gives you compile time checked queries. from there maybe you could cover leptos which is the rust meta framework that is a port of solidjs/solid-start. it has co-located server functions and most of the modern js framework features.

    • @awesome-coding
      @awesome-coding  2 місяці тому

      All great ideas! Thanks for the suggestions!

  • @callanambulancebutnotforme5702
    @callanambulancebutnotforme5702 2 місяці тому +15

    more rust pls

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

    Would love to learn more about Rust. Please post more!

  • @LetrixAR
    @LetrixAR 2 місяці тому +2

    I enjoy using Tauri that uses a Rust backend with a JS frontend

  • @kunodragon4355
    @kunodragon4355 2 місяці тому +3

    Kind of felt like the video was inconclusive. Still, thank you for the peek into Rust!

    • @awesome-coding
      @awesome-coding  2 місяці тому

      Thanks for the feedback - I believe you are right, I should have added some personal conclusions at the end of the video. Will do so in the next ones.

  • @thomasrasser
    @thomasrasser 2 місяці тому +4

    Great video. I would also appreciate the most common way, to solve the compilation error at 4:34

    • @awesome-coding
      @awesome-coding  2 місяці тому +1

      Thanks for the feedback!
      I'm planning more "Snippet" videos, and solving borrow checker errors will be addressed for certain!

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

      You can pass in get_polite(name.clone()).
      This create a copy of that data and pass it in.

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

    deep dive on the double!

  • @cariyaputta
    @cariyaputta 2 місяці тому +6

    Rust is a joy to code in. And the official documentation is great.

  • @stone-snare
    @stone-snare 2 місяці тому

    now that you know rust, you should make a video on the react compiler. i've looked at some of it but i think it would make a nice video.

  • @codelucky
    @codelucky 2 місяці тому +7

    Rust is exciting for a specific purpose.

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

    good video mate

  • @gavenblsn4753
    @gavenblsn4753 2 місяці тому +1

    interested, please more rust. thank you

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

    Currently learning c++ and this come in recommendation😮

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

    We need more rust videos!

  • @Lucs-ku5cb
    @Lucs-ku5cb 2 місяці тому +1

    Make a video about Web Assembly in Rust pls

    • @awesome-coding
      @awesome-coding  2 місяці тому +1

      Will do - it's on my list.
      Thanks for the input!

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

    I think it would be good if when you present a programming language, you tell us the uses of this language. Like javascript is used in the web, C++ in video games...

    • @awesome-coding
      @awesome-coding  2 місяці тому

      You are right - thanks for the suggestion!

  • @JR-hb6jr
    @JR-hb6jr 2 місяці тому

    Can you do one by making a small real world tool?

  • @alejandroj.mendezc.981
    @alejandroj.mendezc.981 2 місяці тому

    Rust Rules!

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

    Rust!!!

  • @nm6x
    @nm6x 2 місяці тому +1

    Lifetimes! Please help me with lifetimes!

    • @awesome-coding
      @awesome-coding  2 місяці тому

      Added it to the list!

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

      yeaaaa count me in lol

  • @zcuric
    @zcuric 2 місяці тому +4

    Throwing bone to ThePrimeagen for views. Just kidding, great video!

    • @awesome-coding
      @awesome-coding  2 місяці тому +5

      😂 Trust me, I'll do way worse things for views 😅

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

    I do not think i can keep up with this..😅

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

    Rust look hard then c++😂

  • @TheTmLev
    @TheTmLev 2 місяці тому +3

    I don't think starting the video by explaining macros is a good idea...

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

      Yeah... I'd definitely use some other examples for a quick look at the language

    • @awesome-coding
      @awesome-coding  2 місяці тому +2

      Right, here is the issue though - this is the "Hello world" example, so you have to address the macro, right? Otherwise people will wonder why the hell you need to put an exclamation mark after the function name.
      The first Object oriented language I learned in year 1 at the University was Java. They started with the following:
      So all programs have to start with "public static void main (String[] args)" but don't worry about what each keyword means, you'll learn it throughout the year. Some people could go past that.. I couldn't :) So I fell it's always better to address the topic, even in passing, than just to lave people wonder about the details. My 2 cents :)

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

      @@awesome-coding That really put me off Java as well, I sitched to Python and was much happier.

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

    So... What are your impressions?
    You just described some of the features of Rust without saying anything about your subjective opinion.
    The video is good, but it's very common for videos about Rust to be like this, so it feels generic.
    If you continue this series, I really recommend adding a section at the end of the video where you express your subjective impressions on the language, what you liked, what not, and why.

    • @awesome-coding
      @awesome-coding  2 місяці тому

      Thank you for your feedback - it is actually very valuable.
      I believe you are right, and I could add a subjective angle to all this.
      I believe that the steep learning curve everybody is complaining about is a real thing, and you need a lot of dedication to get over the initial frustrations. Definitely not a language I would suggest to beginners.
      Other than that, I find its concepts really interesting, and it's always a good exercise to analyse how various languages try to solve problems.
      Definitely, I'd like to continue with this series, because I believe the best way to learn programming concepts is to look at actual code and applied examples. In the next Rust video I'll make sure to add in my impressions as well.

  • @buddy.abc123
    @buddy.abc123 2 місяці тому

    Rust syntax is the only reason I'm not interested in writing it.

    • @awesome-coding
      @awesome-coding  2 місяці тому

      I agree it's pretty over the top, especially if your background is in a language like Java.

  • @cryptonative
    @cryptonative 2 місяці тому +1

    Why learn Rust:
    - Learn new programming concepts eg. macros and algebraic types
    - Systems programming eg. databases, OS, blockchain, cli tools, game dev
    - Observe that coding is becomes easier as the project grows unlike JS/TS
    Why not learn Rust:
    - For frontend dev

    • @awesome-coding
      @awesome-coding  2 місяці тому +1

      Leptos is a pretty good solution for web dev :)

    • @cryptonative
      @cryptonative 2 місяці тому +1

      @@awesome-coding It's not there yet. Long compile times, big wasm size and not much of a performance increase because of glue code. Really have high hopes for it though

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

    third

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

    Moar please 😊 I am so happy to learn that you're unemployed (and a bit sorry too)

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

    If you are still unemployed, then I'm fu*ked(searching for a job)

  • @damiangilz
    @damiangilz 2 місяці тому +1

    All my low level friends quit Rust, so I wont even touch it.

    • @awesome-coding
      @awesome-coding  2 місяці тому

      I am curious to know why :D

    • @bear458ziif-s
      @bear458ziif-s 2 місяці тому +1

      @@awesome-coding probably because there is a crowd of low level engineers that do not like rust because it is not low level enough for them. they are used to c and c++ and do not like that having that many guard rails. i have also heard criticisms of unsafe rust being difficult at times. my complaints with rust are compile times and dealing with async complexity on a library level. aside from library code, developers will rarely come across complexity with async, because crates are designed to be high level and mitigate complexity. however, the things i like about rust outweigh the drawbacks for me personally.

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

      Yeah, too many guardrails which require jumping through many hoops for stuff other programming languages handle seamlessly.

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

      @@awesome-coding Zig/C is better. Rust Is a forced swallow in comparison. In the case of C its a matter of having the right training.

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

    The second a frikin usa government recommended people to use rust, i completely stopped using rust

    • @awesome-coding
      @awesome-coding  2 місяці тому +1

      😂 The US is already building military bases in my country, so I don't think using or not using Rust will make any difference in my case 🤦‍♂️

  • @Peacemaker.404
    @Peacemaker.404 2 місяці тому +1

    first ❤

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

    2:33 Go back to Java 😂

  • @krellin
    @krellin 2 місяці тому +1

    fuck rust, do zig

    • @awesome-coding
      @awesome-coding  2 місяці тому +1

      Great! Now I have to spend another 3 months reading books on another language?! :))

    • @an-eios7125
      @an-eios7125 2 місяці тому +3

      @@awesome-coding Zig is just C with some extra stuff. Some might call it C++

    • @porcupinetree-bb3zg
      @porcupinetree-bb3zg 2 місяці тому +2

      zig is more complicated for web but less complicated for systems programming. you still have to manually free memory with zig whereas the borrow checker is kind of a cross between gc and manual memory management. the type system is really lacking in zig too. zig is more of a c replacement as opposed to it's own language.

    • @awesome-coding
      @awesome-coding  2 місяці тому

      @@an-eios7125 It always sounds easy on paper. I know of Zig because of all the Bun "marketing", but never looked into it in detail.

    • @bear458ziif-s
      @bear458ziif-s 2 місяці тому

      @@awesome-coding don't waste your time learning zig. zig compared to c is basically what kotlin is compared to java. it's not quite that but that's what they're going for. there isn't much incentive to learn it for the sake of learning it. it's just meant to interop well and be relatively similar to c. they didn't invent new concepts or anything.

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

    This is not complicated

  • @CultKosmosa
    @CultKosmosa 2 місяці тому +1

    bbad and uninformative, total waaste of time

    • @awesome-coding
      @awesome-coding  2 місяці тому

      Sorry to hear that. I'd like to know what can be improved if you are willing to share that.

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

      @@awesome-coding idk, come up with original ideas, youre just regurgitating information from other streamers like a dog eating trash. just an analogy, not an insult. And not of the type where you just read the docs, we read the docs thank you. ORIGINality is the commodity and is so rare. Youre just a xerox of a xerox, will keep an eye on you, bet you cannot improve because brain too smol to evolve past this EASY route of sharing trash with people. but hope for the best, cheers

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

    Rust looks awful.

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

    dont_panic.unwrap()