DEV Community

Cover image for My journey in Rust
Bekka
Bekka

Posted on

My journey in Rust

I've decided to start learning Rust and I would like to share my journey with you. In this blog post, I'm going to share my thought process on the introduction to Rust.

What is Rust?

Rust is a multi-paradigm, general purpose programming language designed for performance and safety, especially safe concurrency. It guarantees memory safety by using the "borrow checker" to validate references.

One might ask? what is safe concurrency? what's the borrow checker? I got confused by hearing those new terms, they were certainly new to me, especially the borrow checker. After some research, I found some explanations;

Safe concurrency

Wait, What is concurrency in the first place?
Concurrency is the ability of different parts or units of program to be run in no particular order, without affecting the final outcome.

What if some parts of those programs actually need some data before it can be executed? what if some parts of the program is tampered with or ran into some error, maybe even affected the other parts, (N.B the parts could be a thread or anything else). How do we ensure this safety? Making sure we don't accidentally read or write into other parts of programs that run parallel to each other.

Is this where safe concurrency come in? Yes! you got that right!šŸ˜ƒ. Safe concurrency is when units of programs run in parallel and are isolated such that you can only read their state and not write to them.

What is the borrow checker?

This is an enforcement by Rust itself, It enforces a number of properties, In JavaScript you can move the same value. In Rust, you can't do that, the borrow checker helps to check the lifetime of variables, the mutability, the immutability and the ownership of a variable or data.

Why Rust?

Because of its type safety, Rust is considered one of the most powerful languages. It has speed, fearless concurrency and also memory safety. It can also be considered a system programming language.

Where can you use Rust?

Well, you can use it in a lot of spaces, like Blockchain, embedded system engineering, systems programming, the web (using WASM, YEW or other libaries)

How to start learning Rust?

All you need to do is to go into Rust official website and follow the instructions.

So that's it, I just shared my own process of getting to know rust and why you should use it. What do you wanna do in Rust? Well, I am going to be a Blockchain engineer in Rust. I'm going to share more tips and more thought process as I progress in this journey. I hope you enjoyed my thought process šŸ˜

Top comments (1)

Collapse
 
kingzamzon profile image
Samson Adesanoye

Thank you for sharing