Rust slice

data types

Post thumbnail
Post thumbnail
In Rust, the slice is a primitive type as well as a sequence type. I found slices very confusing at first. In the Rust book, slices are defined as ‘a dynamically-sized view into a contiguous sequence’. [Read More]

Rust tuple

data types

Post thumbnail
Post thumbnail
The Rust tuple is placed in several categories of types. For starters, the tuple is a primitive type. Among others, this means tuples have the Copy trait implemented, making them pass by value. [Read More]

Rust SSH

Learning Rust by building a CLI tool

Post thumbnail
Post thumbnail
Creating small CLI tools is a fun way to get more familiar with a programming language. If you are coming from an infrastructure background, a CLI tool that you can use to send commands to devices/servers might be considered a neat starting point getting into Rust. This is how I... [Read More]

Rust arrays

data types

Post thumbnail
Post thumbnail
In Rust, the array is the simplest of the sequence types (the others being slices and tuples). The array lives on the stack and has a fixed length. The length you declare an array with is part of it’s type and it is going to remain the same throughout the... [Read More]