Rust Programming Course for Beginners - Tutorial

preview_player
Показать описание
Learn the Rust programming language in this course for beginners.

✏️ Shaun Hamilton created this course.

⭐️ Resources ⭐️

Thanks to Replit for providing a grant that made this course possible.

⭐️ Course Contents ⭐️
⌨️ (00:00) Course Introduction
⌨️ (01:16) Rust Overview
⌨️ (02:00) Initialising the CLI Calculator
⌨️ (04:25) Handling Environment Arguments
⌨️ (09:00) Understanding the nth Method
⌨️ (16:00) Parsing Strings into Floats
⌨️ (18:05) Declaring a Function
⌨️ (18:30) If Statements
⌨️ (21:20) Implicit Returns
⌨️ (22:25) Parsing String into Char
⌨️ (23:20) Formatting Output
⌨️ (25:20) Match Control Flow
⌨️ (27:05) Panicking!
⌨️ (28:30) Building a Release
⌨️ (29:30) Initialising the Image Combiner
⌨️ (30:00) Creating Args Module
⌨️ (31:08) Structs
⌨️ (32:30) Declaring the New Module
⌨️ (33:20) Private vs Public
⌨️ (34:30) Implementing the New Function
⌨️ (36:40) Deriving the Debug Trait
⌨️ (37:40) Using get_nth_arg in Struct
⌨️ (38:57) External Crates
⌨️ (39:52) Decoding Images
⌨️ (43:15) Destructuring Tuples
⌨️ (43:56) Importing Missing Types
⌨️ (44:35) Handling Format Errors with Result
⌨️ (46:00) Enums
⌨️ (47:20) Resizing Images
⌨️ (55:00) FloatingImage Struct
⌨️ (56:35) Buffers with Vecs
⌨️ (58:15) TryInto Conversions
⌨️ (1:00:05) Deriving Debug for Enums
⌨️ (1:00:40) Running the Code with Images
⌨️ (1:02:25) Combining the Image Pixels
⌨️ (1:11:20) Understanding Borrows and References
⌨️ (1:12:15) Creating Methods
⌨️ (1:15:20) Error Propagation
⌨️ (1:15:53) Saving the New Image
⌨️ (1:17:30) Using the Image Combiner
⌨️ (1:18:20) Better Error Handling

🎉 Thanks to our Champion and Sponsor supporters:
👾 Raymond Odero
👾 Agustín Kussrow
👾 aldo ferretti
👾 Otis Morgan
👾 DeezMaster

--

Рекомендации по теме
Комментарии
Автор

Great course, thank you. My only issue is the audio is too low to play through my speakers and the static hurts my ears with headphones. I normally watch courses at least twice, but I don't think I can with this one. I don't know much about fixing audio like this, but if you could re-upload with better audio that would be amazing.

ajb
Автор

very cool video. Thank you very much!
i would be very happy if there were also a video about all of the concepts of rust, like shadowing, borrowing, slices, concurrency etc.

alexanderschaub
Автор

This is great, especially if you already know Rust to some degree. It's probably not the right course for a beginner. You already need to know what Option, Result and enums are in order to follow along. Probably would be good to introduce those more explicitly.

ConnorMcCormick
Автор

It’s an interesting choice working with iterators right at the beginning, but you explain them well so it works out. Really good stuff.

paulzupan
Автор

Just yesterday I was looking for a source to dive into rust. Freecode camp are the best! Thank you shan for a great video

LongLiveIsrael-cy
Автор

I have a question about one of the things that you described. In the calculator program you said that the "nth()" iterator will move to the next after returning the current one. Which means that it consumes the current one. Next time when you call nth(), you will end up accessing the next element. So we accessed the nth element like this

args.nth(1).unwrap();
args.nth(0).unwrap();
args.nth(0).unwrap();

In the second implementation we just access the element using the function

fn get_nth_arg(n: usize) -> String {

}

and called this function like

impl Args {
pub fn new() -> Self
{
Args{
image_1: get_nth_arg(1),
image_2: get_nth_arg(2),
output: get_nth_arg(3)
}
}
}

How does the second case work and the first does not?

ajitabhs
Автор

How do you go about making an hour+ video and not check the audio? I appreciate the video but I have the volume maxed on my mac and its still difficult to hear this presenter. This video should be edited to double or triple the audio volume in video and re-uploaded. This is trivial to do in Adobe Premier.

LeakyBuffer
Автор

I have been waiting long time for this . Thank you

qeaq
Автор

the craziest thing is that now i can appreciate rust for its design. a few years ago i would consider it a form of torture.



basically, you spend all of that time writing it to not have to endlessly debug it afterwards. it is also quite expressive, so it is easier to understand someone else's code

chinpokomon_
Автор

This course isn't enough. Please stop displaying it as a "full course in the thumbnail".

rayyanamir
Автор

been waiting for this forever, thanks for the value you guys are adding.

abdelkaderboudaoud
Автор

Great tutorial really enjoyed it especially the end part of error handling, Thank you Shaun:)

akashwebmob
Автор

hey is the mic in another room there lads? haha :)

Rogueixpresents
Автор

This guy is whispering like he recorded this while his home is being raided by pirates.

Pteromandias
Автор

1:19:57 I notice this is idiomatic Rust to NOT tell the exact path of/or the filename when this kind of read(or not found) error happens :)) So what you see is: Error: UnableToReadImageFromPath(Os { code: 2, kind: NotFound, message: "No such file or directory" })
Now it's up to the user to GUESS which filename was not found (in this case, either the first one or the second one, but imagine this happens in a big project). This is literally the reason I stopped trying to learn Rust a few year ago!

correabuscar
Автор

When the instructor introduces a programming language by using concepts that haven't been introduced yet. I'm sure Shaun is knowledgeable, but I feel that this course could've been done much better for beginners. Or, change the title of the video to suit the content.

kylebuttress
Автор

is it just me or is this really hard to grasp even though I understand a bunch of other languages

codaq
Автор

I am really new to Rust, but the last part of the video on the alternative way to work with Result and Option by using match operator and if statement doesn't seem really "clean" to me. It creates a big amount of nested stuff, which is pretty hard to read. Maybe the problem is in the function itself, considering it is doing three things: opens file, loads it into memory and determines format. My OOP brain screams to split this functionallity and probably move to a separate entity, smth like ImageLoader. As for other stuff, awesome tutorial!

hrnk
Автор

39:52 is anyone else running into this error "error: failed to download `rayon-core v1.11.0`"

I literally added the same crate image "0.23.14" the the Cargo.toml file as in the video and now I cant continue and dont find this error anywhere on StackOverflow

nicolasarnedovillanueva
Автор

Not for beginers. Borrowing and ownership are the most important concept of Rust and are not expained.

juangomez