CPP04 1.0
読み取り中…
検索中…
一致する文字列を見つけられません
WrongCat.hpp
[詳解]
1/* ************************************************************************** */
2/* */
3/* ::: :::::::: */
4/* WrongCat.hpp :+: :+: :+: */
5/* +:+ +:+ +:+ */
6/* By: kamitsui <kamitsui@student.42tokyo.jp> +#+ +:+ +#+ */
7/* +#+#+#+#+#+ +#+ */
8/* Created: 2025/05/20 16:27:13 by kamitsui #+# #+# */
9/* Updated: 2025/05/20 23:18:37 by kamitsui ### ########.fr */
10/* */
11/* ************************************************************************** */
12
21#ifndef WRONGCAT_HPP
22#define WRONGCAT_HPP
23
24#include "WrongAnimal.hpp" // Inherits from WrongAnimal
25
34class WrongCat : public WrongAnimal {
35 public:
37 WrongCat(const WrongCat &other);
38 WrongCat &operator=(const WrongCat &other);
39 virtual ~WrongCat();
40
41 void makeSound() const;
42};
43
44#endif
The WrongAnimal class represents a generic animal, used to demonstrate the LACK of polymorphism when ...
The WrongCat class represents a feline animal in the "wrong" hierarchy.
Definition WrongCat.hpp:34
WrongCat(const WrongCat &other)
virtual ~WrongCat()
WrongCat & operator=(const WrongCat &other)
void makeSound() const
Declares the WrongAnimal class.