Answer the question
In order to leave comments, you need to log in
In 3rd class add first 2 as data structure...?
Hello everyone, there is such a question about the structure of the program, before you start writing :) (I will shorten everything only for a specific task), I say in advance that I don’t need to decide anything for me, I just need to understand how it’s possible and how not :)
There are 2 classes:
1) Engine {attributes.... }
2) Tank {Attributes... }
- they have a bunch of functions, etc... I miss this. Here is a task that is not clear:
Make 1 more "rocket" class: This class collects the "engine" and "tank" classes and provides further components that make up the rocket.
It follows that the Attributes of this class have two data structures that can store the unknown meaning of "tanks and engines".
And here is the question itself, what are the possibilities in the implementation of the above-listed? :) Preferably without lists...
maybe somehow attributes of two classes can be stuffed into 1 tract? In general, I want to deal with this in advance, so that later I don’t have to do everything at random)) Prof. I've been sick for 2 months now and haven't gone through this, but I already have to prepare)) I'm trying to do the exams of the past years.
Answer the question
In order to leave comments, you need to log in
And here is the question itself, what are the possibilities in the implementation of the above-listed? :)
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question