Paste Link lets you automatically update the referenced document.
Answer:
a. Object cannot be converted to Person
Explanation:
This program demonstrates polymorphism.
e.g., a Student IS a Person therefore you can call m() with a Student as well as a Person object.
The same goes for GraduateStudent.
However, and Object is not a Person, so the last call fails. This can be deducted by the type checking that happens at compile time.
Answer:
See explaination.
Explanation:
question is the root element which have two children one is M-C and other is Coding.
Again M-C have two sub children Points and parts
Note: The tree will be as shown in the attachment. kindly refer to attachment.
Here if we see the child of quiz(questions) at 0 position is number of type M-C and another child at location 1 is number of type Coding.
Now quiz.child(0) is number of type M-C which has two child and child at 0 is Points and child at 1 is Parts
quiz.child(0).child(1) is Points and now further points doesn't have any children hence going further to quiz.child(0).child(1).child(0) is nothing hence it will not return anything.
Next quiz.child(1) is number of type coding and value is 5.
Size of the tree is (2^depth)-1
and here depth of tree is 3 hence size is (2^3)-1 i.e. 7
Answer:
If left being the shortest file size and right being the biggest file size...
It is JPEG, PNG, TIFF.
Explanation:
TIFF is used primarily for editing photos or for uncompressed high quality images for things like 4K textures. The file size will be bigger since generally it is uncompressed.
PNG reserves the maximum quality of the image and can not be compressed. (It can be compressed but the results are very minimal).
JPEG allows for the user to decide the compression and quality of the image. JPEG also doesn't hold transparency data, thus making JPEG generally use less space than PNG and definitely more than TIFF.
It can make ur eyes blind blind that’s a disadvantage