MuneebRabaney - Overview

@{ Hello World } Codewars

Genius is a fickle beast. Sometimes you have the good fortune to work with a mad genius. Other times you are doomed to work with pure madness. There are also times when it is hard to tell the difference.

I talk to machines. I solve problems. I code. ♥️

  
 struct Human {
  name: String,
}

impl Human {
  fn new(name: String) -> Self {
    Self { name }
  }

  fn display(&self) {
    println!("Name: \n{}", self.name);
  }
}

struct Programmer {
  human: Human,
  title: String,
  stack: Vec<String>,
  languages: Vec<String>,
}

impl Programmer {
  fn new(name: String, title: String, stack: Vec<String>, languages: Vec<String>) -> Self {
    Self {
      human: Human::new(name),
      title,
      stack,
      languages,
    }
  }

  fn display(&self) {
    self.human.display();
    println!("{}", "\n");
    println!("Title: \n{}", self.title);
    println!("{}", "\n");
    println!("Stack:");
    for technology in &self.stack {
      println!("· {}", technology);
    }
    println!("{}", "\n");
    println!("Languages:");
    for language in &self.languages {
      println!("· {}", language);
    }
  }
}

fn main() {
  let programmer = Programmer::new(
    "Muneeb Rabaney".to_string(),
    "Snr. Software Engineer".to_string(),
    vec![
      "Bun".to_string(),
      "Node".to_string(),
      "React".to_string(),
      "DotNet".to_string(),
      "Laravel".to_string(),
    ],
    vec![
      "C".to_string(), 
      "C#".to_string(), 
      "SQL".to_string(),
      "PHP".to_string(),
      "Bash".to_string(),
      "TypeScript".to_string(),
    ],
  );
  programmer.display();
}
Coding

Connect With Me

https://za.linkedin.com/in/muneeb-rabaney https://stackoverflow.com/users/4433536 i.am.he.who.codes


profile for White Rabbit on Stack Exchange, a network of free, community-driven Q&A sites
amplify    apachecordova    aws    azure    babel    bash    bootstrap    chartjs    csharp    css3    docker    dotnet    electron    express    figma    gatsby    git    graphql    gulp    html5    illustrator    ionic    java    javascript    jenkins    laravel    linux    materialize    mongodb    mssql    mysql    nextjs    nginx    nodejs    photoshop    php    postman    puppeteer    react    reactnative    redux    sass    sketch    sqlite    symfony    tailwind    tensorflow    typescript    vagrant    webpack   

muneebrabaney