Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- fn main() {
- let mut goblin = Creature::new();
- let mut fighter = Character::new();
- println!("The priority of the goblin is {}", goblin.get_priority());
- println!("The priority of the fighter is {}", fighter.get_priority());
- println!("Set the priority of the fighter");
- fighter.set_priority(2);
- println!("The priority of the fighter is {} now",
- fighter.get_priority());
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement