Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR RUST

enum rust

#[derive(Debug)]
#[allow(dead_code)]
enum ELanguage {
    Js,
    Rust,
    Java,
    Cpp,
    C
}

#[derive(Debug)]
#[allow(dead_code)]
struct Language {
    name: ELanguage
}


fn main() {
    let language1 = Language {
        name: ELanguage::Rust
    };

    println!("{:#?}", language1)
}
 
PREVIOUS NEXT
Tagged: #enum #rust
ADD COMMENT
Topic
Name
1+7 =