Saturday, May 20, 2023

Rust on android part 3 , if else in rust.

 In this tutorial we are going to learn about if else statement in rust language 


fn main(){

    let num = 10;

    if num < 10 {

        println!("Given number is less than 10");

} else if num == 10{

        println!("Given number is 10");

}else {

        println!("Given number is grater than 10");

}

                }


if else statement in rust look something like this , you can apply logic according to your requirement.


Thanks 

No comments:

Post a Comment

what is free fire phishing and how you can avoid it ?.

 Hello friends in this blog we are going to know how hackers are able to hack your free fire account and taking control of it . We are going...