Answered step by step
Verified Expert Solution
Question
00
1 Approved Answer
Project Index ( static ) Configure x Collapse Introduction to Objects Coding Exercises: Objects ( 6 ) Exercise 5 Exercise 5 The Bigcat class helps
Project Index static Configure Collapse Introduction to Objects Coding Exercises: Objects Exercise Exercise The Bigcat class helps to record information on the animals in the Panthera genus tiger lion, jaguar, leopard, and snow leopard Since all animals are in the same genus, the object will have the default class attribute genus with the string value panthera. The constructor accepts the following parameters in this order: species string with the species of the animal, eg "tigris" commonName string with the common name of the animal, eg "tiger" habitat vector of strings with common locations of the animal, egtropical rainforests", "grasslands" "temperate forests" Your task is to construct a Bigcat object called snowleopard so that when the program runs and prints the information on snowleopard, you will get the following result: Expected Result: A snow leopard is part of the uncia species. Their genus class is panthera. some of their habitats include: Himalaya mountains, Siberian mountains, DO NOT CHANGE the existing code in main.
Project Index static
Configure
Collapse
Introduction to Objects Coding Exercises: Objects
Exercise
Exercise
The Bigcat class helps to record information on the animals in the Panthera genus tiger lion, jaguar, leopard, and snow leopard Since all animals are in the same genus, the object will have the default class attribute genus with the string value panthera. The constructor accepts the following parameters in this order:
species string with the species of the animal, eg "tigris"
commonName string with the common name of the animal, eg "tiger"
habitat vector of strings with common locations of the animal, egtropical rainforests", "grasslands" "temperate forests"
Your task is to construct a Bigcat object called snowleopard so that when the program runs and prints the information on snowleopard, you will get the following result:
Expected Result:
A snow leopard is part of the uncia species.
Their genus class is panthera.
some of their habitats include: Himalaya mountains, Siberian mountains,
DO NOT CHANGE the existing code in main.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access with AI-Powered Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started