<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Carlos Rivas</title>
    <description>The latest articles on DEV Community by Carlos Rivas (@devlikeyou).</description>
    <link>https://dev.to/devlikeyou</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F420753%2F7310e8f6-336c-4138-b94a-f49605b41e24.png</url>
      <title>DEV Community: Carlos Rivas</title>
      <link>https://dev.to/devlikeyou</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/devlikeyou"/>
    <language>en</language>
    <item>
      <title>How to connect and query to Postgresql Golang vs Rust?</title>
      <dc:creator>Carlos Rivas</dc:creator>
      <pubDate>Mon, 14 Mar 2022 14:10:03 +0000</pubDate>
      <link>https://dev.to/devlikeyou/how-to-connect-and-query-to-postgresql-golang-vs-rust-3neb</link>
      <guid>https://dev.to/devlikeyou/how-to-connect-and-query-to-postgresql-golang-vs-rust-3neb</guid>
      <description>&lt;h2&gt;
  
  
  How to connect to Postgresql Golang vs Rust?
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Programming Languages war
&lt;/h3&gt;

&lt;p&gt;Hey, my friends, a new post about this war. I don't know which is better, but I'll try to figure it out. I hope y'all enjoy this series. Here we go!&lt;/p&gt;

&lt;p&gt;It's regular in the job environment to have to connect to databases, in this case, we're going to connect with Postgresql.&lt;/p&gt;

&lt;p&gt;You only need to have to install the Postgresql server (Docker is good too 😉), in my case I had to create a database called "test" and a table called pokemon, pokemon has 3 fields, id, name, type. &lt;/p&gt;

&lt;h3&gt;
  
  
  Golang/Go
&lt;/h3&gt;

&lt;p&gt;First, you need to install a package called "github.com/lib/pq", how to install this package? &lt;/p&gt;

&lt;p&gt;Init the package main with the name of the folder.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;go mod init name_folder
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Get the package from the internet.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;go get -u github.com/lib/pq
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This package is A pure Go/Golang Postgres driver for Go's database/sql package, later we will see how to use it.&lt;/p&gt;

&lt;p&gt;All Go/Golang scripts are the package, so remember to tell it what package is, In this case, is the main.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;package main
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now import all packages we need to write this code.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;import (
    "database/sql" // Package sql provides a generic interface around SQL (or SQL-like) databases. 
    "fmt" // implements formatted I/O
    "log" // implements a simple logging package

    _ "github.com/lib/pq" // Why has underscore at first, that's because I never had to call this package directly.
)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In Go/Golang all you define you have to use it, this is the reason why I have to use underscore because it's the way to define but never I'm going to use it this declaration.&lt;/p&gt;

&lt;p&gt;Define a variable of connection to the database.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const (
    host     = "localhost"
    port     = 5432
    user     = "user"
    password = "password"
    dbname   = "test"
)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Define struct of database table.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;type Pokemon struct {
    ID   int
    Name string
    Type string
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Remember it's the main function because is the entry point to run.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Now, I have to define the connection's string, I need all variables defined before.&lt;/li&gt;
&lt;li&gt;Open the connection with the method Open() from the SQL package with the driver name that I need and the connection's string.&lt;/li&gt;
&lt;li&gt;Validate if the connection has an error. If it doesn't error call with "defer" the method Close() from the SQL package.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  psqlInfo := fmt.Sprintf("host=%s port=%d user=%s password=%s dbname=%s sslmode=disable", host, port, user, password, dbname)
    db, err := sql.Open("postgres", psqlInfo)
    if err != nil {
        log.Fatal(err)
    }

  defer db.Close()
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If you wonder what does "defer" does? It's simple when all code run, the last command will be the one you say in "defer".&lt;/p&gt;

&lt;p&gt;It's time to catch a new Pokemon, who is this Pokemon?&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--dbkl5SvF--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1647198229301/wp9yDsVGK.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--dbkl5SvF--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1647198229301/wp9yDsVGK.jpg" alt="metapod.jpg" width="480" height="360"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;I use the "struct" to define the values that I need to create the register.&lt;/li&gt;
&lt;li&gt;After, I create a value with the SQL script to insert, returning the id.&lt;/li&gt;
&lt;li&gt;With the method QueryRow, It needs the query and the values necessary to insert after that I use the method Scan to add the id to a struct called Pokemon.&lt;/li&gt;
&lt;li&gt;I check if it has an error and print the register.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  myNewPokemon := Pokemon{
        Name: "Metapod",
        Type: "Bug",
    }

    insertSql := "INSERT INTO pokemons (name, type) VALUES ($1, $2) RETURNING id"
    err = db.QueryRow(insertSql, myNewPokemon.Name, myNewPokemon.Type).Scan(&amp;amp;myNewPokemon.ID)
    if err != nil {
        log.Fatal(err)
    }
    fmt.Printf("%+v\n", myNewPokemon)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now, It's time to fight, Metapod I choose you.&lt;/p&gt;

&lt;p&gt;In this case, I need to get one register from the database, the steps are similar:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;I declare a variable with the type Struct. (This is only to show that each register is in different variables)&lt;/li&gt;
&lt;li&gt;I create the SQL script to find it in the database.&lt;/li&gt;
&lt;li&gt;With the method QueryRow, it executes the query with the value necessary, and with the method Scan, it inserts the register in the struct.&lt;/li&gt;
&lt;li&gt;I check if it has an error and print the register.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  var myPokemon Pokemon
    selectSql := `SELECT * FROM pokemons WHERE id = $1`
    err = db.QueryRow(selectSql, myNewPokemon.ID).Scan(&amp;amp;myPokemon.ID, &amp;amp;myPokemon.Name, &amp;amp;myPokemon.Type)
    if err != nil {
        log.Fatal(err)
    }

    fmt.Printf("%+v\n", myPokemon)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;What is that, is Metapod evolving?&lt;/p&gt;

&lt;p&gt;Now, it's time to update:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;I declare a variable with the type Struct. (This is only to show that each register is in different variables)&lt;/li&gt;
&lt;li&gt;I create the SQL script to update the database.&lt;/li&gt;
&lt;li&gt;With the method QueryRow, it executes the query with the value necessary, and with the method Scan, it inserts the register in the struct.&lt;/li&gt;
&lt;li&gt;I check if it has an error and print the register.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    var evolution Pokemon
    updateSql := "UPDATE pokemons SET name = $1, type = $2 WHERE id = $3 RETURNING id, name, type"
    err = db.QueryRow(updateSql, "Butterfree", "Bug Flying", myPokemon.ID).Scan(&amp;amp;evolution.ID, &amp;amp;evolution.Name, &amp;amp;evolution.Type)
    if err != nil {
        log.Fatal(err)
    }
    fmt.Printf("%+v\n", evolution)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Anyone wants this moment?, but I have to let free my Butterfree, He fell in love:&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--guv1dupd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1647198340169/uhizU-TQO.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--guv1dupd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1647198340169/uhizU-TQO.jpg" alt="ashcriying.jpg" width="880" height="665"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I have to delete, remember the delete methods are so dangerous, be careful.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;I declare a variable with the type Struct. (This is only to show that each register is in different variables)&lt;/li&gt;
&lt;li&gt;I create the SQL script to delete the database.&lt;/li&gt;
&lt;li&gt;With the method QueryRow, it executes the query with the value necessary, and with the method Scan, it inserts the register in the struct.&lt;/li&gt;
&lt;li&gt;I check if it has an error and print the register.
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    var byePokemon Pokemon
    deleteSql := "DELETE FROM pokemons WHERE id = $1 RETURNING id, name, type"
    err = db.QueryRow(deleteSql, evolution.ID).Scan(&amp;amp;byePokemon.ID, &amp;amp;byePokemon.Name, &amp;amp;byePokemon.Type)
    if err != nil {
        log.Fatal(err)
    }
    fmt.Printf("%+v\n", byePokemon)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;I have good pokemons yet.&lt;/p&gt;

&lt;p&gt;In the end, how to show all registers in the database:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;I create the SQL script to read in the database.&lt;/li&gt;
&lt;li&gt;With the method QueryRow, it executes the query with the value necessary.&lt;/li&gt;
&lt;li&gt;I check if it has an error.&lt;/li&gt;
&lt;li&gt;I have to close the connection with the method close, and I use "defer", you know why, if you don't know why, you can read a little higher.&lt;/li&gt;
&lt;li&gt;I declare a variable with the type Struct, in this case, is an array because I want to show all pokemons.&lt;/li&gt;
&lt;li&gt;I read each row and associate it with other variables in each column, with the method Scan.&lt;/li&gt;
&lt;li&gt;I check if it has an error and add the register to the array.&lt;/li&gt;
&lt;li&gt;Print the registers.
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  rows, err := db.Query("SELECT * FROM pokemons")
    if err != nil {
        log.Fatal(err)
    }

    defer rows.Close()
    var myPokemons []Pokemon
    for rows.Next() {
        var pokemon Pokemon
        err = rows.Scan(&amp;amp;pokemon.ID, &amp;amp;pokemon.Name, &amp;amp;pokemon.Type)
        if err != nil {
            log.Fatal(err)
        }

        myPokemons = append(myPokemons, pokemon)
    }

    fmt.Printf("%+v\n", myPokemons)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;Here is all my code in Go/Golang. And now it's our code. 🤓&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;package main

import (
    "database/sql"
    "fmt"
    "log"

    _ "github.com/lib/pq"
)

const (
    host     = "localhost"
    port     = 5432
    user     = "user"
    password = "password"
    dbname   = "test"
)

type Pokemon struct {
    ID   int
    Name string
    Type string
}

func main() {
    psqlInfo := fmt.Sprintf("host=%s port=%d user=%s password=%s dbname=%s sslmode=disable", host, port, user, password, dbname)
    db, err := sql.Open("postgres", psqlInfo)
    if err != nil {
        log.Fatal(err)
    }
    defer db.Close()

    // Create
    myNewPokemon := Pokemon{
        Name: "Metapod",
        Type: "Bug",
    }

    insertSql := "INSERT INTO pokemons (name, type) VALUES ($1, $2) RETURNING id"
    err = db.QueryRow(insertSql, myNewPokemon.Name, myNewPokemon.Type).Scan(&amp;amp;myNewPokemon.ID)
    if err != nil {
        log.Fatal(err)
    }
    fmt.Printf("%+v\n", myNewPokemon)

    // Read one register
    var myPokemon Pokemon
    selectSql := `SELECT * FROM pokemons WHERE id = $1`
    err = db.QueryRow(selectSql, myNewPokemon.ID).Scan(&amp;amp;myPokemon.ID, &amp;amp;myPokemon.Name, &amp;amp;myPokemon.Type)
    if err != nil {
        log.Fatal(err)
    }
    fmt.Printf("%+v\n", myPokemon)

    // Update
    var evolution Pokemon
    updateSql := "UPDATE pokemons SET name = $1, type = $2 WHERE id = $3 RETURNING id, name, type"
    err = db.QueryRow(updateSql, "Butterfree", "Bug Flying", myPokemon.ID).Scan(&amp;amp;evolution.ID, &amp;amp;evolution.Name, &amp;amp;evolution.Type)
    if err != nil {
        log.Fatal(err)
    }
    fmt.Printf("%+v\n", evolution)

    // Delete
    var byePokemon Pokemon
    deleteSql := "DELETE FROM pokemons WHERE id = $1 RETURNING id, name, type"
    err = db.QueryRow(deleteSql, evolution.ID).Scan(&amp;amp;byePokemon.ID, &amp;amp;byePokemon.Name, &amp;amp;byePokemon.Type)
    if err != nil {
        log.Fatal(err)
    }
    fmt.Printf("%+v\n", byePokemon)

    // Read all
    rows, err := db.Query("SELECT * FROM pokemons")
    if err != nil {
        log.Fatal(err)
    }
    defer rows.Close()

    var myPokemons []Pokemon
    for rows.Next() {
        var pokemon Pokemon
        err = rows.Scan(&amp;amp;pokemon.ID, &amp;amp;pokemon.Name, &amp;amp;pokemon.Type)
        if err != nil {
            log.Fatal(err)
        }

        myPokemons = append(myPokemons, pokemon)
    }
    fmt.Printf("%+v\n", myPokemons)

}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Rust
&lt;/h3&gt;

&lt;p&gt;The first part is to add all dependencies necessary to execute this code. Remember these dependencies should add in the file Cargo.toml&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[dependencies]
serde = { version = "1.0", features = ["derive"] } # framework for serializing and deserializing Rust data structures efficiently and generically.
postgres = "0.19.2" # A synchronous client for the PostgreSQL database.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now I'm going to the file main.rs&lt;/p&gt;

&lt;p&gt;First, call the modules necessary to run this code.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;use serde::{Serialize};
use postgres::{Client, NoTls, Error};
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Define struct of database table&lt;/p&gt;

&lt;h1&gt;
  
  
  [derive] This is able to implement a trait, which means that, how you can see, after this line, define a structure, I know that I need to get this information from a database, so, to achieve to serializing this information, I have to say how to structure with serializing or debug.
&lt;/h1&gt;

&lt;p&gt;So, #[derive(Debug, Serialize)], Serialize, I used this to can change the name "type" to "ty" and Debug allows me to show variable with this operator {:?}&lt;/p&gt;

&lt;p&gt;If you wonder why did I have to use rename? The reason is that type is a reserved keyword, then, exist two options.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;using rename ( I like this more).&lt;/li&gt;
&lt;li&gt;using r#type can escape reserved keywords.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;#[derive(Debug, Serialize)]
struct Pokemon {
    id: i32,
    name: String,
    #[serde(rename = "type")]
    ty: String,
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Remember it's the main function because is the entry point to run.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Now, I have to define the connection's string.&lt;/li&gt;
&lt;li&gt;Open the connection with the method connect() from the SQL package with the string of connection.&lt;/li&gt;
&lt;li&gt;To “unwrap” something in Rust is to say, “Give me the result of the computation, and if there was an error, panic and stop the program.”
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    let mut client = Client::connect("postgresql://user:password@localhost:5432/test", NoTls).unwrap();
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It's time to catch a new pokemon, who is this pokemon?&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--NNm2zJXW--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1647198473173/n9HrA2iGd.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--NNm2zJXW--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1647198473173/n9HrA2iGd.jpg" alt="squirtle.jpg" width="880" height="495"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;I use the "struct" to define the values that I need to create the register.&lt;/li&gt;
&lt;li&gt;After, I create a value with the SQL script to insert, returning the id.&lt;/li&gt;
&lt;li&gt;With the method query_one need the query and the values necessary to insert after that I use the method "get" to add the id to the struct called Pokemon.&lt;/li&gt;
&lt;li&gt;Print the register.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    let mut my_new_pokemon = Pokemon {
        id: 0,
        name:  "Squirtle".to_string(),
        ty:  "Water".to_string(),
    };
    let insert_sql = "INSERT INTO pokemons (name, type) VALUES ($1, $2) RETURNING id";
    let row = client.query_one(insert_sql, &amp;amp;[&amp;amp;my_new_pokemon.name, &amp;amp;my_new_pokemon.ty])?;
    my_new_pokemon.id = row.get(0);
    println!("{:#?}", my_new_pokemon);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now, It's time to fight, Squirtle I choose you.&lt;br&gt;
In this case, I need to get one register from the database, the steps are similar:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;I create the SQL script to find it in the database.&lt;/li&gt;
&lt;li&gt;With the method query_one execute the query with the value necessary.&lt;/li&gt;
&lt;li&gt;I declare a variable with the type Struct and with the method "get", I insert the register in the struct. (This is only to show that each register is in different variables)&lt;/li&gt;
&lt;li&gt;Print the register.
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    let select_sql = "SELECT * FROM pokemons WHERE id = $1";
    let row = client.query_one(select_sql, &amp;amp;[&amp;amp;my_new_pokemon.id])?;
    let my_pokemon = Pokemon {
        id: row.get(0),
        name:  row.get(1),
        ty:  row.get(2),
    };
    println!("{:#?}", my_pokemon);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;What is that, is Squirtle evolving?&lt;br&gt;
Now, it's time to update:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;I create two variables with the name and type of this pokemon.&lt;/li&gt;
&lt;li&gt;I create the SQL script to update the database.&lt;/li&gt;
&lt;li&gt;With the method query_one execute the query with the value necessary.&lt;/li&gt;
&lt;li&gt;I declare a variable with the type Struct and with the method "get", I insert the register in the struct. (This is only to show that each register is in different variables)&lt;/li&gt;
&lt;li&gt;Print the register.
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    let pokemon_name =  "Wartortle".to_string();
    let pokemon_type =  "Water".to_string();
    let update_sql = "UPDATE pokemons SET name = $1, type = $2 WHERE id = $3 RETURNING id, name, type";
    let row = client.query_one(update_sql, &amp;amp;[&amp;amp;pokemon_name, &amp;amp;pokemon_type, &amp;amp;my_pokemon.id])?;
    let evolution = Pokemon {
        id: row.get(0),
        name:  row.get(1),
        ty:  row.get(2),
    };
    println!("{:#?}", evolution);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;Anyone wants this moment?, but I have to let free my Wartortle because is a great leader and the Squirtle squad need one, I know the story is not original.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--guv1dupd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1647198340169/uhizU-TQO.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--guv1dupd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1647198340169/uhizU-TQO.jpg" alt="ashcriying.jpg" width="880" height="665"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I have to delete, remember the delete methods are so dangerous, be careful.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;I create the SQL script to delete the database.&lt;/li&gt;
&lt;li&gt;With the method query_one execute the query with the value necessary.&lt;/li&gt;
&lt;li&gt;I declare a variable with the type Struct and with the method "get", I insert the register in the struct. (This is only to show that each register is in different variables)&lt;/li&gt;
&lt;li&gt;Print the register.
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    let delete_sql = "DELETE FROM pokemons WHERE id = $1 RETURNING id, name, type";
    let row = client.query_one(delete_sql, &amp;amp;[&amp;amp;evolution.id])?;
    let bye_pokemon = Pokemon {
        id: row.get(0),
        name:  row.get(1),
        ty:  row.get(2),
    };
    println!("{:#?}", bye_pokemon);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;I have good pokemons yet.&lt;/p&gt;

&lt;p&gt;In the end, how to show all registers in the database:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;I declare a variable with the type Struct, in this case, is a vector because I want to show all pokemons.&lt;/li&gt;
&lt;li&gt;I create the SQL script to read in the database, with the method query execute the query with the value necessary and I go through the rows that get the query.&lt;/li&gt;
&lt;li&gt;I declare a variable with the type Struct and with the method "get", I insert the register in the struct. (This is only to show that each register is in different variables).&lt;/li&gt;
&lt;li&gt;With the method push, I add to the vector each row.&lt;/li&gt;
&lt;li&gt;Print the registers.
&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    let mut my_pokemons:Vec&amp;lt;Pokemon&amp;gt; = vec![];
    for row in client.query("SELECT * FROM pokemons", &amp;amp;[]).unwrap() {
        let pokemon = Pokemon {
            id: row.get(0),
            name: row.get(1),
            ty: row.get(2),
        };
        my_pokemons.push(pokemon);
    }
    println!("{:#?}", my_pokemons);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;Here is all my code in Rust. And now it's our code. 🤓&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;use serde::{Serialize};
use postgres::{Client, NoTls, Error};

#[derive(Debug, Serialize)]
struct Pokemon {
    id: i32,
    name: String,
    #[serde(rename = "type")]
    ty: String,
}

fn main() -&amp;gt; Result&amp;lt;(), Error&amp;gt;{
    let mut client = Client::connect("postgresql://user:password@localhost:5432/test", NoTls).unwrap();

    // Create
    let mut my_new_pokemon = Pokemon {
        id: 0,
        name:  "Squirtle".to_string(),
        ty:  "Water".to_string(),
    };
    let insert_sql = "INSERT INTO pokemons (name, type) VALUES ($1, $2) RETURNING id";
    let row = client.query_one(insert_sql, &amp;amp;[&amp;amp;my_new_pokemon.name, &amp;amp;my_new_pokemon.ty])?;
    my_new_pokemon.id = row.get(0);
    println!("{:#?}", my_new_pokemon);

    // Read
    let select_sql = "SELECT * FROM pokemons WHERE id = $1";
    let row = client.query_one(select_sql, &amp;amp;[&amp;amp;my_new_pokemon.id])?;
    let my_pokemon = Pokemon {
        id: row.get(0),
        name:  row.get(1),
        ty:  row.get(2),
    };
    println!("{:#?}", my_pokemon);

    // Update
    let pokemon_name =  "Wartortle".to_string();
    let pokemon_type =  "Water".to_string();
    let update_sql = "UPDATE pokemons SET name = $1, type = $2 WHERE id = $3 RETURNING id, name, type";
    let row = client.query_one(update_sql, &amp;amp;[&amp;amp;pokemon_name, &amp;amp;pokemon_type, &amp;amp;my_pokemon.id])?;
    let evolution = Pokemon {
        id: row.get(0),
        name:  row.get(1),
        ty:  row.get(2),
    };
    println!("{:#?}", evolution);

    // Delete
    let delete_sql = "DELETE FROM pokemons WHERE id = $1 RETURNING id, name, type";
    let row = client.query_one(delete_sql, &amp;amp;[&amp;amp;evolution.id])?;
    let bye_pokemon = Pokemon {
        id: row.get(0),
        name:  row.get(1),
        ty:  row.get(2),
    };
    println!("{:#?}", bye_pokemon);

    // Read all
    let mut my_pokemons:Vec&amp;lt;Pokemon&amp;gt; = vec![];
    for row in client.query("SELECT * FROM pokemons", &amp;amp;[]).unwrap() {
        let pokemon = Pokemon {
            id: row.get(0),
            name: row.get(1),
            ty: row.get(2),
        };
        my_pokemons.push(pokemon);
    }
    println!("{:#?}", my_pokemons);
    Ok(())
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Conclusion&lt;/p&gt;

&lt;p&gt;Structure: It's similar, Maybe the principal difference between them, it's that Go/Golang uses "if" in each iteration to validate if has an error, this is because Go/Golang doesn't have exceptions.&lt;br&gt;
Lines: Golang: 91, Rust: 69&lt;br&gt;
Easy to get information: For me It was easier to get information from Go/Golang than Rust.&lt;br&gt;
Execution time: In this example, the difference is not decisive.&lt;/p&gt;

&lt;p&gt;Would you like that I write more info about the database? What would be your first pokemon?&lt;/p&gt;

&lt;p&gt;I hope you enjoy my post and remember that I am just a Dev like you!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--CecblyI1--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1647198505933/DwVbK9w2C.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--CecblyI1--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1647198505933/DwVbK9w2C.jpg" alt="dejavu.jpg" width="880" height="660"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>crud</category>
      <category>rust</category>
      <category>go</category>
      <category>database</category>
    </item>
    <item>
      <title>How to create a rest API client Golang vs Rust?</title>
      <dc:creator>Carlos Rivas</dc:creator>
      <pubDate>Mon, 24 Jan 2022 14:16:19 +0000</pubDate>
      <link>https://dev.to/devlikeyou/how-to-create-a-rest-api-client-golang-vs-rust-1dl7</link>
      <guid>https://dev.to/devlikeyou/how-to-create-a-rest-api-client-golang-vs-rust-1dl7</guid>
      <description>&lt;h2&gt;
  
  
  How to create a rest API client Golang vs Rust?
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Programming Languages war
&lt;/h3&gt;

&lt;p&gt;Hey, my friends, a new post about this war.&lt;/p&gt;

&lt;p&gt;I don't know which is better, but I'll try to figure it out. I hope y'all enjoy this series. Here we go!&lt;/p&gt;

&lt;p&gt;A RESTful API is an architectural style for an application program interface (API) that uses HTTP requests to access and use data.&lt;/p&gt;

&lt;p&gt;Why the people use that? It's because every time we have to communicate between microservices o services, obviously exist other ways to communicate that, but it's the most popular.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--XpTuhC7C--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1642879722367/nXzuSvcVG.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--XpTuhC7C--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1642879722367/nXzuSvcVG.png" alt="rest.png" width="880" height="664"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;In this case, I'm going to use an API about Chuck Norris Jokes, and how I can get information to manipulate between endpoints.&lt;/p&gt;

&lt;p&gt;The endpoint is the URL where we can get information.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--kUbl2XTp--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1642879501763/luxGJR1Rp.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--kUbl2XTp--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1642879501763/luxGJR1Rp.jpeg" alt="CebC4f1WIAAiJW0.jpg" width="555" height="369"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Golang/Go&lt;/p&gt;

&lt;p&gt;The first part is to import all packages necessary to execute this code.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;package main

import (
    "encoding/json" // package json implements encoding and decoding of JSON
    "fmt" // implements formatted I/O
    "io/ioutil" // implements some I/O utility functions
    "log" // implements a simple logging package
    "math/rand" // implements pseudo-random number generators unsuitable for security-sensitive work
    "net/http" // provides HTTP client and server implementations
    "time" // provides functionality for measuring and displaying time

    "github.com/davecgh/go-spew/spew" // implements a deep pretty printer for Go data structures to aid in debugging.
)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The next code define the structure of how to manipulate the response from API&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;type Joke struct {
    ID         string   `json:"id"`
    Value      string   `json:"value"`
    Categories []string `json:"categories"`
    URL        string   `json:"url"`
    CreatedAt  string   `json:"created_at"`
    IconURL    string   `json:"icon_url"`
    UpdatedAt  string   `json:"updated_at"`
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The next code is the main function, remember it's the main function because is the entry point to run.&lt;/p&gt;

&lt;p&gt;What does the main function do?&lt;/p&gt;

&lt;p&gt;I initialize the time, why I do that, it's to know how long the execution lasts, next, I call the function getCategory (I'm going to explain this function after spoiler alert, get a category), after that with this information I call other function call getJoke( You know what happen here), in the end, I calculate the time and print the execution lasts.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--EMgHv79B--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1642879821017/T5N3MglZo.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--EMgHv79B--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1642879821017/T5N3MglZo.jpeg" alt="spoileralert.jpg" width="880" height="336"&gt;&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;func main() {
    start := time.Now()

    var category = getCategory()

    getJoke(category)
    elapsed := time.Since(start)
    fmt.Printf("Execution lasts: %s\n", elapsed)
}

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;I hope you're enjoying this post, I enjoy doing that. OK, I'm going to continue with this:&lt;/p&gt;

&lt;p&gt;getCategory function:&lt;/p&gt;

&lt;p&gt;I start my HTTP client, this client is who can get information from endpoint or services, so, It's who will tell us the joke, but first the category, after that, I use another method from HTTP, NewRequest, this method makes the request, what do I need for a request?&lt;/p&gt;

&lt;p&gt;Verb + Endpoint or URL + data, in this case, we don't need data but what happens here, in Golang we have the use the keyword nil, to say I don't have data to send you.&lt;/p&gt;

&lt;p&gt;this method returns two values, request or error.&lt;/p&gt;

&lt;p&gt;I validate if I don't have errors and if I don't have anything to cry I can continue.&lt;/p&gt;

&lt;p&gt;After, I use our client to call the method Do with the value request and to receive two values, response or error.&lt;/p&gt;

&lt;p&gt;Again I cross my fingers and pray for good news.&lt;/p&gt;

&lt;p&gt;I read the body responds with the method ReadAll from the package ioutil, and again I can receive two values (I know, I know), body or error.&lt;/p&gt;

&lt;p&gt;It's important to know-how is the response, you can use the client to that (Hoppscotch or Postman) or print your body (fmt.Printf("%s", body)), Exist different ways to show you the response, but the most popular is JSON.&lt;/p&gt;

&lt;p&gt;What means []string, this is a type of data, it says an array of strings, after that I use the method Unmarshal from JSON to say this information that is a JSON and I know is an array of string put in a variable that I defined as an array of strings, but, this method only returns one value, if it's an error, what happens is not an error? the variable bodyArray gets the data in this format.&lt;/p&gt;

&lt;p&gt;You can ask why I have to convert my data in an array of strings, this is because is the ways easiest to use this information.&lt;/p&gt;

&lt;p&gt;I receive an array with 16 positions, which means I have 16 strings which mean different categories, but I need one.&lt;/p&gt;

&lt;p&gt;My option is to get this information randomly, for that, I use the method Seed from rand package to say that for each execution I want other numbers.&lt;/p&gt;

&lt;p&gt;In the end, I have to return a value from my array, with this method I get an integer value between 0 and the length of array rand.Intn(len(bodyArray).&lt;/p&gt;

&lt;p&gt;This return something like that for instance "bodyArray[10]"&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;func getCategory() string {
    client := http.Client{}
    request, err := http.NewRequest("GET", "https://api.chucknorris.io/jokes/categories", nil)
    if err != nil {
        log.Fatal(err)
    }
    response, err := client.Do(request)
    if err != nil {
        log.Fatal(err)
    }
    defer response.Body.Close()

    body, err := ioutil.ReadAll(response.Body)
    if err != nil {
        log.Fatal(err)
    }

    var bodyArray []string
    newErr := json.Unmarshal(body, &amp;amp;bodyArray)
    if newErr != nil {
        log.Fatal(newErr)
    }
    rand.Seed(time.Now().UnixNano())

    return bodyArray[rand.Intn(len(bodyArray))]
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;getJoke function:&lt;/p&gt;

&lt;p&gt;The first steps are the same as the before function, the unique difference is the endpoint and response format.&lt;/p&gt;

&lt;p&gt;The Unmarshal method is from the JSON package, translating the body response to joke structure.&lt;/p&gt;

&lt;p&gt;Now it's time to use the Dump and the structure. Well, I'm going to start at the beginning.&lt;/p&gt;

&lt;p&gt;the Dump is only to show the pretty way a structure something like that&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;{
 ID: (string) (len=22) "0wdewlp2tz-mt_upesvrjw",
 Value: (string) (len=136) "Chuck Norris does not follow fashion trends, they follow him. But then he turns around and kicks their ass. Nobody follows Chuck Norris.",
 Categories: ([]string) (len=1 cap=4) {
  (string) (len=7) "fashion"
 },
 URL: (string) (len=55) "https://api.chucknorris.io/jokes/0wdewlp2tz-mt_upesvrjw",
 CreatedAt: (string) (len=26) "2020-01-05 13:42:18.823766",
 IconURL: (string) (len=59) "https://assets.chucknorris.host/img/avatar/chuck-norris.png",
 UpdatedAt: (string) (len=26) "2020-01-05 13:42:18.823766"
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;But if you want to use any value from this structure, you have to use variable name + . + structure value name.&lt;/p&gt;

&lt;p&gt;Ex: joke.Value&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;func getJoke(category string) {
    client := http.Client{}
    request, err := http.NewRequest("GET", "https://api.chucknorris.io/jokes/random?category="+category, nil)
    if err != nil {
        log.Fatal(err)
    }

    response, err := client.Do(request)
    if err != nil {
        log.Fatal(err)
    }
    defer response.Body.Close()

    body, err := ioutil.ReadAll(response.Body)
    if err != nil {
        log.Fatal(err)
    }

    var joke Joke
    newErr := json.Unmarshal(body, &amp;amp;joke)
    if newErr != nil {
        log.Fatal(newErr)
    }

    spew.Dump(joke)
    fmt.Println(joke.Value)
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here is all my code in Golang.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;package main

import (
    "encoding/json"
    "fmt"
    "io/ioutil"
    "log"
    "math/rand"
    "net/http"
    "time"

    "github.com/davecgh/go-spew/spew"
)

type Joke struct {
    ID         string   `json:"id"`
    Value      string   `json:"value"`
    Categories []string `json:"categories"`
    URL        string   `json:"url"`
    CreatedAt  string   `json:"created_at"`
    IconURL    string   `json:"icon_url"`
    UpdatedAt  string   `json:"updated_at"`
}

func main() {
    start := time.Now()

    var category = getCategory()

    getJoke(category)
    elapsed := time.Since(start)
    fmt.Printf("Execution lasts: %s\n", elapsed)
}

func getCategory() string {
    client := http.Client{}
    request, err := http.NewRequest("GET", "https://api.chucknorris.io/jokes/categories", nil)
    if err != nil {
        log.Fatal(err)
    }
    response, err := client.Do(request)
    if err != nil {
        log.Fatal(err)
    }
    defer response.Body.Close()

    body, err := ioutil.ReadAll(response.Body)
    if err != nil {
        log.Fatal(err)
    }

    var bodyArray []string
    newErr := json.Unmarshal(body, &amp;amp;bodyArray)
    if newErr != nil {
        log.Fatal(newErr)
    }
    rand.Seed(time.Now().UnixNano())

    return bodyArray[rand.Intn(len(bodyArray))]
}

func getJoke(category string) {
    client := http.Client{}
    request, err := http.NewRequest("GET", "https://api.chucknorris.io/jokes/random?category="+category, nil)
    if err != nil {
        log.Fatal(err)
    }

    response, err := client.Do(request)
    if err != nil {
        log.Fatal(err)
    }
    defer response.Body.Close()

    body, err := ioutil.ReadAll(response.Body)
    if err != nil {
        log.Fatal(err)
    }

    var joke Joke
    newErr := json.Unmarshal(body, &amp;amp;joke)
    if newErr != nil {
        log.Fatal(newErr)
    }

    spew.Dump(joke)
    fmt.Println(joke.Value)
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Rust&lt;/p&gt;

&lt;p&gt;The first part is to add all dependencies necessary to execute this code. Remember these dependencies should add in the file Cargo.toml&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[dependencies]
reqwest = { version = "0.11", features = ["json"] } # provides a convenient, higher-level HTTP Client.
tokio = { version = "1", features = ["full"] } # an event-driven, non-blocking I/O platform for writing asynchronous applications
serde = { version = "1", features = ["derive"] }  # framework for serializing and deserializing Rust data structures efficiently and generically.
serde_json = "1.0" # A JSON serialization file format
futures = "0.3" # provides a number of core abstractions for writing asynchronous code
rand = "0.8.4" # provides utilities to generate random numbers
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now I'm going to the file main.rs&lt;/p&gt;

&lt;p&gt;First, call the modules necessary to run this code.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;use rand::Rng;
use serde::Deserialize;
use std::time::Instant;
use reqwest::Client;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;#[derive] This is able to implement a trait, which means that, how you can see, after this line, define a structure, I know that I need to get this information from a JSON, so, to achieve to deserializing this information, I have to say how to structure with deserializing or debug.&lt;/p&gt;

&lt;p&gt;So, #[derive(Deserialize, Debug)], Deserialize can translate a JSON in a struct and Debug allows me to show variable with this operator {:?}&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;#[derive(Deserialize, Debug)]
struct Joke {
    id: String,
    value: String,
    categories: Vec&amp;lt;String&amp;gt;,
    created_at: String,
    icon_url: String,
    updated_at: String,
    url: String,
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The #[tokio::main] function is a macro. It transforms the async fn main() into a synchronous fn main() that initializes a runtime instance and executes the async main function. Here can you read a little more information about &lt;a href="https://tokio.rs/tokio/tutorial/hello-tokio"&gt;tokio&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The next code is the main function, remember it's the main function because is the entry point to run.&lt;/p&gt;

&lt;p&gt;What does the main function do?&lt;/p&gt;

&lt;p&gt;I initialize the time, why do I do that? it's to know how long the execution lasts, next, I call the function get_category (I'm going to explain this function after, spoiler alert, get a category, looks like a Deja bu), after that with this information I call another function call get_joke( You know what happen here), in the end, I calculate the time and print the execution lasts.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--8eqBoo-n--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1642880058541/D4-Dr75X3.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--8eqBoo-n--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1642880058541/D4-Dr75X3.jpeg" alt="dejavu.jpg" width="880" height="660"&gt;&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;#[tokio::main]
async fn main() {
    let start = Instant::now();
    let category = get_category().await;
    get_joke(category).await;
    let end = start.elapsed();
    println!("Execution lasts: {:?}", end);
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;get_category function:&lt;/p&gt;

&lt;p&gt;First, I define the function and say what type of data I have to return.&lt;/p&gt;

&lt;p&gt;After I instantiate and I use the method get who needs the endpoint or URL how parameter, next, the method send() and await (Can you guess what does it do?) and unwrap.&lt;/p&gt;

&lt;p&gt;To “unwrap” something in Rust is to say, “Give me the result of the computation, and if there was an error, panic and stop the program.”  If you want to know a little more about &lt;a href="http://web.mit.edu/rust-lang_v1.25/arch/amd64_ubuntu1404/share/doc/rust/html/book/first-edition/error-handling.html#:~:text=To%20%E2%80%9Cunwrap%E2%80%9D%20something%20in%20Rust,the%20Option%20and%20Result%20types."&gt;Error Handling&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Then, I translate the JSON response to Vector of String.&lt;/p&gt;

&lt;p&gt;Count the length to the categories response.&lt;/p&gt;

&lt;p&gt;Retrieve the lazily-initialized thread-local random number generator, seeded by the system. More &lt;a href="https://docs.rs/rand/0.6.5/rand/fn.thread_rng.html"&gt;info&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;return a string randomly from 0 and the length in categories.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;async fn get_category() -&amp;gt; String {
    let res1 = Client::new()
        .get("https://api.chucknorris.io/jokes/categories")
        .send()
        .await
        .unwrap();

    let categories = res1.json::&amp;lt;Vec&amp;lt;String&amp;gt;&amp;gt;().await.unwrap();
    let count = categories.len();
    let mut rng = rand::thread_rng();

    categories[rng.gen_range(0..count)].to_string()
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;get_joke function:&lt;/p&gt;

&lt;p&gt;The first steps are the same as the before function, the unique difference is the endpoint and response format.&lt;/p&gt;

&lt;p&gt;format! is a macro that allows uniting two or more strings.&lt;/p&gt;

&lt;p&gt;Then, I translate the JSON response to the Joke struct.&lt;/p&gt;

&lt;p&gt;If you ask the difference between {#?} and {?} It's only to show pretty the structure and looks like that:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Joke {
    id: "6sdvoj-msgi6miv07ekctq",
    value: "Chuck Norris is currently suing myspace for taking the name of what he calls everything around you.",
    categories: [
        "dev",
    ],
    created_at: "2020-01-05 13:42:19.104863",
    icon_url: "https://assets.chucknorris.host/img/avatar/chuck-norris.png",
    updated_at: "2020-01-05 13:42:19.104863",
    url: "https://api.chucknorris.io/jokes/6sdvoj-msgi6miv07ekctq",
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;But if you want to use any value from this structure, you have to use variable name + . + structure value name.&lt;/p&gt;

&lt;p&gt;Ex: joke.value&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;async fn get_joke(category: String) {
    let res1 = Client::new()
        .get(format!(
            "https://api.chucknorris.io/jokes/random?category={}",
            category
        ))
        .send()
        .await
        .unwrap();

    let joke = res1.json::&amp;lt;Joke&amp;gt;().await.unwrap();
    println!("{:#?}", joke);
    println!("{:?}", joke.value);
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here is all my code in Rust.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;use rand::Rng;
use serde::Deserialize;
use std::time::Instant;
use reqwest::Client;


#[derive(Deserialize, Debug)]
struct Joke {
    id: String,
    value: String,
    categories: Vec&amp;lt;String&amp;gt;,
    created_at: String,
    icon_url: String,
    updated_at: String,
    url: String,
}

#[tokio::main]
async fn main() {
    let start = Instant::now();
    let category = get_categories().await;
    get_joke(category).await;
    let end = start.elapsed();
    println!("Execution lasts: {:?}", end);
}

async fn get_category() -&amp;gt; String {
    let res1 = Client::new()
        .get("https://api.chucknorris.io/jokes/categories")
        .send()
        .await
        .unwrap();

    let categories = res1.json::&amp;lt;Vec&amp;lt;String&amp;gt;&amp;gt;().await.unwrap();
    let count = categories.len();
    let mut rng = rand::thread_rng();

    categories[rng.gen_range(0..count)].to_string()
}

async fn get_joke(category: String) {
    let res1 = Client::new()
        .get(format!(
            "https://api.chucknorris.io/jokes/random?category={}",
            category
        ))
        .send()
        .await
        .unwrap();

    let joke = res1.json::&amp;lt;Joke&amp;gt;().await.unwrap();
    println!("{:#?}", joke);
    println!("{:?}", joke.value);
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Conclusion&lt;/p&gt;

&lt;p&gt;Structure:&lt;br&gt;
    Golang needs more steps to get and to read the information from the endpoint.&lt;br&gt;
    Golang uses camelCase structure to define variables and functions, but, Rust uses snake_case.&lt;br&gt;
    Golang used 88 lines of code and Rust used 54 plus 16 lines from Cargo.toml files&lt;/p&gt;

&lt;p&gt;Lasts&lt;br&gt;
    I run 5 times each code and get this average:&lt;br&gt;
    Golang: 3.33s&lt;br&gt;
    Rust: 4.44s&lt;/p&gt;

&lt;p&gt;But I think it is not enough to know who is better.&lt;/p&gt;

&lt;p&gt;What do you think? Do you want to know a little more about API Client and other methods?&lt;/p&gt;

&lt;p&gt;If you want to know a little more about &lt;a href="https://devlikeyou.com/programming-languages-war-golang-vs-rust-define-variables"&gt;Golang or Rust&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I hope you enjoy my post and remember that I am just a Dev like you!&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Programming Languages war Golang vs Rust Define Variables</title>
      <dc:creator>Carlos Rivas</dc:creator>
      <pubDate>Fri, 26 Nov 2021 13:55:29 +0000</pubDate>
      <link>https://dev.to/devlikeyou/programming-languages-wargolang-vs-rustdefine-variables-2fn1</link>
      <guid>https://dev.to/devlikeyou/programming-languages-wargolang-vs-rustdefine-variables-2fn1</guid>
      <description>&lt;h2&gt;
  
  
  Define Variables
&lt;/h2&gt;

&lt;p&gt;Hey, my friends, a new post about this war.&lt;/p&gt;

&lt;p&gt;I don't know which is better, but I'll try to figure it out. I hope y'all enjoy this series. Here we go!&lt;/p&gt;

&lt;p&gt;In this opportunity I'm going to check up the deep basic information that these languages could hide, I think I'm being dramatic. 😅&lt;/p&gt;

&lt;p&gt;We're going to figure out how to define variables.&lt;/p&gt;

&lt;p&gt;I'm going to do a little script with all examples and a little more. =D&lt;/p&gt;

&lt;h2&gt;
  
  
  Variables
&lt;/h2&gt;

&lt;p&gt;It's a space of memory where you could save information what you need to manipulate. These two languages need to define the type of variable in front of the name or not. It's important to say that exist boolean, numbers, strings, and others.&lt;/p&gt;

&lt;h2&gt;
  
  
  Golang/Go
&lt;/h2&gt;

&lt;p&gt;Before defining variables, I'm going to write about the structure&lt;/p&gt;

&lt;p&gt;Do you remember our hello.go&lt;/p&gt;

&lt;p&gt;hello.go&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;package main import "fmt"
func main() {
  fmt.Println("Hello, World!")
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;The first line: Tells the Go compiler that the package should compile as an executable.&lt;/li&gt;
&lt;li&gt;Second line: Import fmt, fmt is a core library package that contains functionalities related to formatting and printing output. &lt;/li&gt;
&lt;li&gt;And the end func main() is the entry point of an executable program.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Now you know theory things now I'm going to make magic. Ok no. I'm going to make code.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--QNKjl6sH--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1637851463630/tCVJ-WRgZ.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--QNKjl6sH--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1637851463630/tCVJ-WRgZ.gif" alt="magic.gif" width="480" height="268"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It's indispensable that you know that exist var and const like special words to define variables and constants.&lt;/p&gt;

&lt;p&gt;Example&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const NAME string = "Luffy"
func main() {
  var country string = "Brazil"
  fmt.Printf("Hello, %s from %s\n", NAME, country)
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;But Go is so smart, then doesn't need that you tell him the type, he can discover it.&lt;/p&gt;

&lt;p&gt;Example&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;func main() {
  var color = "Blue"
  var number = 20
  fmt.Printf("Type: %T Value: %v\n", number, number)
  fmt.Printf("Type: %T Value: %v\n", color, color)
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;These are all basic types of variables that exist in Golang&lt;/p&gt;

&lt;p&gt;Boolean: bool&lt;/p&gt;

&lt;p&gt;String: string&lt;/p&gt;

&lt;p&gt;Integers:&lt;br&gt;
int int8 int16 int32 int64&lt;br&gt;
uint uint8 uint16 uint32 uint64 uintptr&lt;/p&gt;

&lt;p&gt;Byte:&lt;br&gt;
byte // alias for uint8&lt;/p&gt;

&lt;p&gt;Rune:&lt;br&gt;
rune // alias for int32&lt;br&gt;
     // represents a Unicode code point&lt;/p&gt;

&lt;p&gt;Float:&lt;br&gt;
float32 float64&lt;/p&gt;

&lt;p&gt;Complex:&lt;br&gt;
complex64 complex128&lt;/p&gt;

&lt;p&gt;The last trick that I'm going to use is to disappear the word "var"&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;func main() {
  crew := "Straw Hat Pirates"
  fmt.Printf("Type: %T Value: %v\n", crew, crew)
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;I almost forget something important, the zero value, what means that?&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;func main() {
  var i int
  var f float64
  var b bool
  var s string
  fmt.Printf("%v %v %v %q\n", i, f, b, s)
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Each type of variable has a value by default, Then if you declare a variable, but you don't initialize it, the variable is going to take the default value.&lt;/p&gt;

&lt;p&gt;You can use any method to declare a variable, but I recommend that you should specify the datatype to new variables.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--PciG15O1--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1637851606114/9eo83aICz.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--PciG15O1--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1637851606114/9eo83aICz.gif" alt="challenge-accepted-let-the-challenge-commence.gif" width="220" height="149"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The last challenge if you want to try it. What if?&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;func main() {
  number := 1 number = "one"
  fmt.Printf("%v \n", number)
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Rust
&lt;/h2&gt;

&lt;p&gt;Before defining variables, I'm going to write about the structure. What is that, a déjà vu?&lt;/p&gt;

&lt;p&gt;Do you remember our main.rs&lt;/p&gt;

&lt;p&gt;main.rs&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;fn main() {
  println!("Hello, world!");
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;fn main() is always the first code that runs in every executable Rust program.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Rust has Variables, Variables Mutability, and Constants&lt;/p&gt;

&lt;p&gt;It's indispensable that you know that exist let, let mut, and const like special words to define variables and constants.&lt;/p&gt;

&lt;p&gt;Example&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;const NAME: &amp;amp;str = "Nami";
fn main() {
  let country: &amp;amp;str = "Swedish";
  println!("Hello, {} from {}!", NAME, country);
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The difference between let and let mut, let: you can't change the value of the variable, and let mut you can.&lt;/p&gt;

&lt;p&gt;But if "let" you can't change and constant either, what is the difference?&lt;/p&gt;

&lt;p&gt;In addition to the declaration are "let" or "const", in the constant the type of the value must be annotated and can be declared in any scope.&lt;/p&gt;

&lt;p&gt;Rust is so smart too because it doesn't need that you tell him the type, he can discover it.&lt;/p&gt;

&lt;p&gt;Example&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;use typename::TypeName;
fn main() {
  let color = "Blue";
  let number = 18;
  println!("Type: {}, value: {}", color.type_name_of(), color);
  println!("Type: {}, value: {}", number.type_name_of(), number);
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Add this like dependence, in the file Cargo.toml&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[dependencies]typename = "0.1.1"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;I know that I haven't explained that, but believe me, it's way easier to show the type of data with this method, in another post, I'm going to explain that.&lt;/p&gt;

&lt;p&gt;These are all basic types of variables that exist in Rust&lt;/p&gt;

&lt;p&gt;Boolean: bool&lt;/p&gt;

&lt;p&gt;String: &amp;amp;str&lt;/p&gt;

&lt;p&gt;Character: char&lt;/p&gt;

&lt;p&gt;Integers:&lt;br&gt;
i8 i16 i32 i64 i128 isize&lt;br&gt;
u8 u16 u32 u64 u128 usize&lt;/p&gt;

&lt;p&gt;Float:&lt;br&gt;
f32 f64&lt;/p&gt;

&lt;p&gt;Rust does not have NULL, then you can't do something like that:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;fn main() {
  let color: &amp;amp;str;
  let number: i8;
  println!("Value: {}", number);
  println!("Value: {}", color);
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--PciG15O1--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1637851606114/9eo83aICz.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--PciG15O1--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1637851606114/9eo83aICz.gif" alt="challenge-accepted-let-the-challenge-commence.gif" width="220" height="149"&gt;&lt;/a&gt;&lt;br&gt;
And again the same challenge, what if?&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;fn main() {
  let mut number = 1;
  number = "one";
  println!("Value: {}", number);
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The last thing that you should know, I am sure you noticed semicolon use, is not mandatory in the last line of code, but if you have to write more than one line, you have to use a semicolon.&lt;/p&gt;

&lt;p&gt;My recommendation about semicolons is to use them all the time. But if you forget, the language will tell you. 😉&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;Structure: They are very similar but Golang is easier than Rust because you don't have to use a semicolon or external dependence to print type of value, and Rust for now is not possible to use null or zero value.&lt;/p&gt;

&lt;p&gt;Then this time Golang takes a little advantage over Rust.&lt;/p&gt;

&lt;p&gt;But I think it is not enough to know who is better.&lt;/p&gt;

&lt;p&gt;What do you think? Is the same for you?&lt;/p&gt;

&lt;p&gt;I hope you enjoy my post and remember that I am just a Dev like you!&lt;/p&gt;

</description>
      <category>go</category>
      <category>rust</category>
      <category>beginners</category>
      <category>programming</category>
    </item>
    <item>
      <title>Programming Languages war Golang vs Rust</title>
      <dc:creator>Carlos Rivas</dc:creator>
      <pubDate>Sat, 20 Nov 2021 02:21:29 +0000</pubDate>
      <link>https://dev.to/devlikeyou/programming-languages-war-golang-vs-rust-eb5</link>
      <guid>https://dev.to/devlikeyou/programming-languages-war-golang-vs-rust-eb5</guid>
      <description>&lt;h2&gt;
  
  
  Install new fighters
&lt;/h2&gt;

&lt;p&gt;I'm back, first if anyone miss my post I offer my apologizes, but I was without inspiration, but I'm here again with new fighters.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--HkBov2vM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918199365/zT0yzqZ02.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--HkBov2vM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918199365/zT0yzqZ02.gif" alt="wwe-the-miz.gif" width="498" height="280"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Ladies and gentlemen, in this corner first appeared in 2009 with memory safety, garbage collection, structural typing and is loved according to Stack Overflow 2021 by 62.74% Goooooolang&lt;/p&gt;

&lt;p&gt;Now the next fighter had the first appeared in 2010 with memory safety without garbage collection, reference counting is optional and is loved according to Stack Overflow 2021 by 86.98% Ruuuuuuuust.&lt;/p&gt;

&lt;p&gt;Note: Please read that like WWE or Boxing presentations.&lt;/p&gt;

&lt;p&gt;Now we're going with the tech stuff, but remember, I don't know which is better, but I'll try to figure it out. I hope y'all enjoy this series. Obviously We have to start the installation and amazing "Hello, World!". The whole series I'm going to use SO Ubuntu, then if you need support for other SO I'm going to be here to help you.&lt;/p&gt;

&lt;p&gt;Pre requirements&lt;/p&gt;

&lt;p&gt;Install curl&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;apt install curl&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--6LGi2lhu--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918238470/ZGDqJF4t_.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--6LGi2lhu--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918238470/ZGDqJF4t_.png" alt="Screenshot_20211113_191136.png" width="880" height="184"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Golang/Go
&lt;/h2&gt;

&lt;p&gt;This is our recipe to install Golang/Go&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Step 1:&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Download golang from the website &lt;a href="https://golang.org/doc/install#download"&gt;https://golang.org/doc/install#download&lt;/a&gt; I recommend to use curl to download the file&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;curl https://dl.google.com/go/go1.17.3.linux-amd64.tar.gz --output go1.17.3.linux-amd64.tar.gz 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--ncZ55DQc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918278230/FRTl9Ymuh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--ncZ55DQc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918278230/FRTl9Ymuh.png" alt="Screenshot_20211113_194718.png" width="880" height="59"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Step 2&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Now you have to decompress the file in folder /usr/local&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;rm -rf /usr/local/go &amp;amp;&amp;amp; tar -C /usr/local -xzf go1.17.3.linux-amd64.tar.gz&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Step 3&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Add to the file .bashrc the next line&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;export PATH=$PATH:/usr/local/go/bin&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--fdJEkrIC--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918319793/dVUuvYZsG.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--fdJEkrIC--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918319793/dVUuvYZsG.png" alt="Screenshot_20211113_195304.png" width="595" height="140"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;After that, close the shell or run&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;. .bashrc&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--wLHOXoyU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918338070/DAQj-y88b.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--wLHOXoyU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918338070/DAQj-y88b.png" alt="Screenshot_20211113_195413.png" width="253" height="32"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you run that and has an output, all was good&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;go version&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--lb3XKgWf--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918348180/Joip8mvi1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--lb3XKgWf--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918348180/Joip8mvi1.png" alt="Screenshot_20211113_195451.png" width="307" height="39"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Step 4&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Create a folder and join in it&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;mkdir hello
cd hello/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Step 5&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You have to enable dependency tracking for your code&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;go mod init example/hello&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--LtAAQhu8--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918387345/Xw07k3uPd.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--LtAAQhu8--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918387345/Xw07k3uPd.png" alt="Screenshot_20211113_195840.png" width="491" height="33"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Step 6&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You have to create a file, can you guess the name?&lt;br&gt;
  Image tic tac&lt;/p&gt;

&lt;p&gt;hello.go&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  package main

  import "fmt"

  func main() {
      fmt.Println("Hello, World!")
  }
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Step 7&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It's time to run our program&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;go run .&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--2IcT-TZ3--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918490532/shkmLdU-7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--2IcT-TZ3--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918490532/shkmLdU-7.png" alt="Screenshot_20211113_200155.png" width="388" height="37"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Rust
&lt;/h2&gt;

&lt;p&gt;This is our recipe to install Rust&lt;/p&gt;

&lt;p&gt;Pre requirements&lt;br&gt;
  Install build-essential&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;apt install build-essential&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--_-pI8IM6--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918544963/gXt47uXSp8.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--_-pI8IM6--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918544963/gXt47uXSp8.png" alt="Screenshot_20211113_192506.png" width="880" height="246"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Step 1&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Download the tools that you need to run the rust language from the website &lt;a href="https://www.rust-lang.org/tools/install"&gt;https://www.rust-lang.org/tools/install&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Q-6k-URD--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918584064/1D5Nmk3Fp.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Q-6k-URD--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918584064/1D5Nmk3Fp.png" alt="Screenshot_20211113_191305.png" width="700" height="703"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--GoTwF738--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918608149/ScSPj4Xmm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--GoTwF738--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918608149/ScSPj4Xmm.png" alt="Screenshot_20211113_191803.png" width="700" height="131"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;You only require to choose the first option&lt;/p&gt;

&lt;p&gt;And run that&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;source $HOME/.cargo/env&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--BP3y5Mhi--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918619033/iEADMtQYY.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--BP3y5Mhi--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918619033/iEADMtQYY.png" alt="Screenshot_20211113_191847.png" width="700" height="24"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Step 2&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This tool is called "cargo", this tool creates all structure for you and do other things, but this time only you create the structure&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;cargo new hello_world&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--UlZDBTqC--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918635297/WwRutkD5k.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--UlZDBTqC--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918635297/WwRutkD5k.png" alt="Screenshot_20211113_191944.png" width="486" height="44"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;By default, "cargo" creates this structure with the file to make our "Hello world!"&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--81ByB-WP--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918665275/GF5x4GEhk.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--81ByB-WP--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918665275/GF5x4GEhk.png" alt="Screenshot_20211113_192115.png" width="353" height="99"&gt;&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  fn main() {
      println!("Hello, world!");
  }
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Step 3&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It's time to run our program, you can guess how to?&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;cargo run&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--bGBLyX47--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918686627/vPSfe6wYb.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--bGBLyX47--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918686627/vPSfe6wYb.png" alt="Screenshot_20211113_210545.png" width="521" height="83"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Resume&lt;/p&gt;

&lt;p&gt;Entertainment fight, Golang starts with its better punch, show a simple structure, but Rust responds with fewer steps to run, Golang requires import the package "fmt" to print with "Println" something and Rust needs to use the macro Println, by the way both have the same method ending with "ln" you know why? To add a break line. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--_KgXqXmb--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918799429/Tel-fU5B6.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--_KgXqXmb--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://cdn.hashnode.com/res/hashnode/image/upload/v1636918799429/Tel-fU5B6.gif" alt="icegif-607.gif" width="498" height="256"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This is our first view about two amazing languages, how you could see we can use any language in so many environments for the same things, but which is better, today we can see a few conclusions:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Golang/Go requires more step to run.&lt;/li&gt;
&lt;li&gt;Golang requires import packages to print, and Rust uses macros to the same.&lt;/li&gt;
&lt;li&gt;Rust in addition to the language, install the tool "cargo" can run and create the structure base to Rust.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I hope you enjoy my post and remember that I am just a Dev like you!&lt;/p&gt;

</description>
      <category>go</category>
      <category>rust</category>
      <category>beginners</category>
    </item>
    <item>
      <title>My first conference</title>
      <dc:creator>Carlos Rivas</dc:creator>
      <pubDate>Tue, 30 Jun 2020 15:18:18 +0000</pubDate>
      <link>https://dev.to/devlikeyou/my-first-conference-313h</link>
      <guid>https://dev.to/devlikeyou/my-first-conference-313h</guid>
      <description>&lt;p&gt;Today I want to say how I felt about this first conference called Unconf 2020, When I arrived the email, It was very strange, they tell me, somebody recommends me, for I will be a part of a conference, The first I thought to be this message is real?, I used twitter for looking for about this conference, I didn’t anything about this, then I thought it’s not real, Then I told my wife that I had been invited to a conference about tech o remote work, but I think is false, My wife told me, but you are looking for in google, then I googled this conference and I found it, It was a feel a little strange, but It was real.&lt;/p&gt;

&lt;p&gt;Then I join my personal data, I selected which subject I want to talk, then arrived a second email. It said the conference will be in English. It’s not possible, they told me that it was like a conference TED 5 minute, a little introduce me, then my wife told me you have to do, Then I started to write in Spanish my speech, I have to think about what I want to write, then I tell myself I want to talk about remote work, I had a lot time before pandemic worked whit this method then I think I can talk about this.&lt;/p&gt;

&lt;p&gt;I wrote my speech while the days pass, I have thought yet may be false, Who invited me, I choose no write in my twitter about this, I don’t want feeling dispoinment.&lt;br&gt;
June 20th, 2020, I wake up early, I practice my speech in English over and over, My speech will be at 11:00 am Venezuela, then I joined in the zoom, I was the last people who talk this day, I was very nervous, the other people speak English very well, I don’t speak English yet, but I don’t give up I’m going to try all times, obviously I had a lot fear but, when was my turn I said what I had to read and this was my speech:&lt;/p&gt;

&lt;p&gt;“ Hi, my name is Carlos Rivas I’m a developer from Venezuela, I was thinking about what I can talk about, code maybe, javascript, php, but the first thing I really thought about was because I, I did that someone recommended me, who recommended me or if this was true, It’s obviously true, but what I mean is that impostor syndrome called me again.&lt;/p&gt;

&lt;p&gt;And not only that, the mail that arrives to me says that the presentation is in English, I do not speak English, but I promised not to give up and here I am from Venezuela, against all adversity and prognosis, with bad internet, with bad electrical system, with daily problems, but happy. I can do what I like: program. Thanks to the COVID new job opportunities appeared and I am not afraid to try every day, to strive every day to be better professional, better person. Thanks to technology we can communicate better, we can be better professionals and we can compete with us to be better every day and surpass ourselves.&lt;/p&gt;

&lt;p&gt;So what am I gonna talk about?&lt;br&gt;
I decided it was work from home. It’s the most wonderful invention from the light, having a couch to lay on, a shoulder to cry on or a warm hug to motivate you, which we don’t usually have working from an office for fear of the one they’ll say, maybe, because someone’s gonna look weak, or take advantage of you, because let’s be realistic it’s very common! but in the house, you can be as strong as the arms that embrace you or as confident as the good morning or as motivated as the children wanting to be Messi or Ter Stegen, you can be your, with your fears, failures and self-destruction, but with your joy, your dreams and illusions, it’s obviously hard to have a meeting with kids running around, or screaming because one hit the ball to the other, but that’s also you, the father, the friend, the husband, the student, the one who knows nothing when I miss a semicolon or the one who knows everything when the code compiles at first. All those you, you get stronger every day, maybe someday I’ll go back to work in an office, but I don’t really want it.&lt;/p&gt;

&lt;p&gt;Let’s always remember that our office doesn’t have to be a particular place, I just know that we should stay comfortable with our space, if you have a great space better, but if you have a small desk that meets all your needs that will guarantee you better concentration and performance in your activities.&lt;/p&gt;

&lt;p&gt;In the end what I want to convey is that we must value that which many thought was the best thing to separate the work from the house, so as not to carry unnecessary burdens from one side to the other, But maybe that mix is the one that will give you more peace of mind, more opportunities and more courage in facing the new problems, says a Venezuelan who asked for all the problems for us.&lt;/p&gt;

&lt;p&gt;So remote work for me was what I looked for so long, I looked for happiness and found remote work.&lt;/p&gt;

&lt;p&gt;And as Muhamad Ali said, “Don’t count the days, make the days count.”&lt;/p&gt;

&lt;p&gt;Thank you.”&lt;/p&gt;

&lt;p&gt;Now I am very proud, I do not give up, this day I chose I have to help many people who are afraid to try. If I can, you can.&lt;/p&gt;

&lt;p&gt;Because I am a dev like you!&lt;/p&gt;

</description>
      <category>motivation</category>
      <category>gratitude</category>
    </item>
  </channel>
</rss>
