1
0
This repository has been archived on 2025-01-26. You can view files and clone it, but cannot push or open issues or pull requests.
CPP_Module_04/ex01/main.cpp
2024-12-06 16:06:57 +01:00

42 lines
1.6 KiB
C++

/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* main.cpp :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: adjoly <adjoly@student.42angouleme.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2024/12/06 11:20:59 by adjoly #+# #+# */
/* Updated: 2024/12/06 15:58:25 by adjoly ### ########.fr */
/* */
/* ************************************************************************** */
#include "Dog.hpp"
#include "Cat.hpp"
int main() {
const Animal* dog = new Dog();
Cat* cat = new Cat();
cat->setIdea("I want to eat", 0);
cat->setIdea("I want to eat", 1);
cat->setIdea("I want to eat", 2);
cat->setIdea("I want to eat", 3);
cat->setIdea("I want to eat", 4);
cat->setIdea("I want to eat", 5);
cat->setIdea("I want to eat", 6);
dog->makeSound();
cat->makeSound();
log("🥩", "Idea", "Cat", cat->getIdea(0));
log("🥩", "Idea", "Cat", cat->getIdea(1));
log("🥩", "Idea", "Cat", cat->getIdea(2));
log("🥩", "Idea", "Cat", cat->getIdea(3));
log("🥩", "Idea", "Cat", cat->getIdea(4));
log("🥩", "Idea", "Cat", cat->getIdea(5));
log("🥩", "Idea", "Cat", cat->getIdea(6));
delete cat;
delete dog;
return 0;
}