SlideShare a Scribd company logo
a. Create an arbitrary class without any attributes and methods. b. Write a class named
PLANETS, which should have the following data attributes: - name (for the name of the planet) -
diameter (for the diameter of the planet) - distance (for the distance from sun of the planet) -
length (for the length of year of the planet) c. Inside the class PLANET, define a method called
number_of_moons () which return a message including the planet name and number of moons in
that planet with the default value 0 . (Hint: number of moons is the method input). d. Create a
child class Earth that will inherit all of the variables and methods of the PLANET class. e. Create
an object from child class Earth that will inherit all of the variables and methods of the parent
Vehicle class and display it. Expected Output: Planet Name: Venus Planet Diameter (miles):
7520 Planet distance (million miles) : 67 Planet length of year (days): 225

More Related Content

More from amazefootwear

A. To calculate and display the number of records in Random Access Fi.pdf
 A. To calculate and display the number of records in Random Access Fi.pdf A. To calculate and display the number of records in Random Access Fi.pdf
A. To calculate and display the number of records in Random Access Fi.pdf
amazefootwear
 
A. The map below shows the boundaries between the major plates. Write.pdf
 A. The map below shows the boundaries between the major plates. Write.pdf A. The map below shows the boundaries between the major plates. Write.pdf
A. The map below shows the boundaries between the major plates. Write.pdf
amazefootwear
 
a. The function call for a function named dog that has no parame.pdf
 a. The  function call for a function named  dog that has  no parame.pdf a. The  function call for a function named  dog that has  no parame.pdf
a. The function call for a function named dog that has no parame.pdf
amazefootwear
 
a. Simple Columnar b. Stratified Cuboidal c. Pseudostratified d. Tran.pdf
 a. Simple Columnar b. Stratified Cuboidal c. Pseudostratified d. Tran.pdf a. Simple Columnar b. Stratified Cuboidal c. Pseudostratified d. Tran.pdf
a. Simple Columnar b. Stratified Cuboidal c. Pseudostratified d. Tran.pdf
amazefootwear
 
A. Mantenga el tama�o del equipo peque�o. B. Financie al .pdf
 A. Mantenga el tama�o del equipo peque�o. B. Financie al .pdf A. Mantenga el tama�o del equipo peque�o. B. Financie al .pdf
A. Mantenga el tama�o del equipo peque�o. B. Financie al .pdf
amazefootwear
 
a. Oligodendrocytes Produces myelin around a singular b. Astrocytes.pdf
 a. Oligodendrocytes Produces myelin around a singular b. Astrocytes.pdf a. Oligodendrocytes Produces myelin around a singular b. Astrocytes.pdf
a. Oligodendrocytes Produces myelin around a singular b. Astrocytes.pdf
amazefootwear
 
a. Ellie is 15 and claimed as a dependent by her parents. She has $1,.pdf
 a. Ellie is 15 and claimed as a dependent by her parents. She has $1,.pdf a. Ellie is 15 and claimed as a dependent by her parents. She has $1,.pdf
a. Ellie is 15 and claimed as a dependent by her parents. She has $1,.pdf
amazefootwear
 
A. Discuss which corporate diversification strategy (reference sectio.pdf
 A. Discuss which corporate diversification strategy (reference sectio.pdf A. Discuss which corporate diversification strategy (reference sectio.pdf
A. Discuss which corporate diversification strategy (reference sectio.pdf
amazefootwear
 
A. Definici�n clara del problema que se est� estudiando. B..pdf
 A. Definici�n clara del problema que se est� estudiando. B..pdf A. Definici�n clara del problema que se est� estudiando. B..pdf
A. Definici�n clara del problema que se est� estudiando. B..pdf
amazefootwear
 

More from amazefootwear (9)

A. To calculate and display the number of records in Random Access Fi.pdf
 A. To calculate and display the number of records in Random Access Fi.pdf A. To calculate and display the number of records in Random Access Fi.pdf
A. To calculate and display the number of records in Random Access Fi.pdf
 
A. The map below shows the boundaries between the major plates. Write.pdf
 A. The map below shows the boundaries between the major plates. Write.pdf A. The map below shows the boundaries between the major plates. Write.pdf
A. The map below shows the boundaries between the major plates. Write.pdf
 
a. The function call for a function named dog that has no parame.pdf
 a. The  function call for a function named  dog that has  no parame.pdf a. The  function call for a function named  dog that has  no parame.pdf
a. The function call for a function named dog that has no parame.pdf
 
a. Simple Columnar b. Stratified Cuboidal c. Pseudostratified d. Tran.pdf
 a. Simple Columnar b. Stratified Cuboidal c. Pseudostratified d. Tran.pdf a. Simple Columnar b. Stratified Cuboidal c. Pseudostratified d. Tran.pdf
a. Simple Columnar b. Stratified Cuboidal c. Pseudostratified d. Tran.pdf
 
A. Mantenga el tama�o del equipo peque�o. B. Financie al .pdf
 A. Mantenga el tama�o del equipo peque�o. B. Financie al .pdf A. Mantenga el tama�o del equipo peque�o. B. Financie al .pdf
A. Mantenga el tama�o del equipo peque�o. B. Financie al .pdf
 
a. Oligodendrocytes Produces myelin around a singular b. Astrocytes.pdf
 a. Oligodendrocytes Produces myelin around a singular b. Astrocytes.pdf a. Oligodendrocytes Produces myelin around a singular b. Astrocytes.pdf
a. Oligodendrocytes Produces myelin around a singular b. Astrocytes.pdf
 
a. Ellie is 15 and claimed as a dependent by her parents. She has $1,.pdf
 a. Ellie is 15 and claimed as a dependent by her parents. She has $1,.pdf a. Ellie is 15 and claimed as a dependent by her parents. She has $1,.pdf
a. Ellie is 15 and claimed as a dependent by her parents. She has $1,.pdf
 
A. Discuss which corporate diversification strategy (reference sectio.pdf
 A. Discuss which corporate diversification strategy (reference sectio.pdf A. Discuss which corporate diversification strategy (reference sectio.pdf
A. Discuss which corporate diversification strategy (reference sectio.pdf
 
A. Definici�n clara del problema que se est� estudiando. B..pdf
 A. Definici�n clara del problema que se est� estudiando. B..pdf A. Definici�n clara del problema que se est� estudiando. B..pdf
A. Definici�n clara del problema que se est� estudiando. B..pdf
 

Recently uploaded

Community pharmacy- Social and preventive pharmacy UNIT 5
Community pharmacy- Social and preventive pharmacy UNIT 5Community pharmacy- Social and preventive pharmacy UNIT 5
Community pharmacy- Social and preventive pharmacy UNIT 5
sayalidalavi006
 
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
GeorgeMilliken2
 
PCOS corelations and management through Ayurveda.
PCOS corelations and management through Ayurveda.PCOS corelations and management through Ayurveda.
PCOS corelations and management through Ayurveda.
Dr. Shivangi Singh Parihar
 
The simplified electron and muon model, Oscillating Spacetime: The Foundation...
The simplified electron and muon model, Oscillating Spacetime: The Foundation...The simplified electron and muon model, Oscillating Spacetime: The Foundation...
The simplified electron and muon model, Oscillating Spacetime: The Foundation...
RitikBhardwaj56
 
Chapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.pptxChapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.pptx
Mohd Adib Abd Muin, Senior Lecturer at Universiti Utara Malaysia
 
The basics of sentences session 6pptx.pptx
The basics of sentences session 6pptx.pptxThe basics of sentences session 6pptx.pptx
The basics of sentences session 6pptx.pptx
heathfieldcps1
 
Cognitive Development Adolescence Psychology
Cognitive Development Adolescence PsychologyCognitive Development Adolescence Psychology
Cognitive Development Adolescence Psychology
paigestewart1632
 
How to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP ModuleHow to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP Module
Celine George
 
Walmart Business+ and Spark Good for Nonprofits.pdf
Walmart Business+ and Spark Good for Nonprofits.pdfWalmart Business+ and Spark Good for Nonprofits.pdf
Walmart Business+ and Spark Good for Nonprofits.pdf
TechSoup
 
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptxC1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
mulvey2
 
Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...
Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...
Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...
Dr. Vinod Kumar Kanvaria
 
How to Fix the Import Error in the Odoo 17
How to Fix the Import Error in the Odoo 17How to Fix the Import Error in the Odoo 17
How to Fix the Import Error in the Odoo 17
Celine George
 
Executive Directors Chat Leveraging AI for Diversity, Equity, and Inclusion
Executive Directors Chat  Leveraging AI for Diversity, Equity, and InclusionExecutive Directors Chat  Leveraging AI for Diversity, Equity, and Inclusion
Executive Directors Chat Leveraging AI for Diversity, Equity, and Inclusion
TechSoup
 
writing about opinions about Australia the movie
writing about opinions about Australia the moviewriting about opinions about Australia the movie
writing about opinions about Australia the movie
Nicholas Montgomery
 
RPMS TEMPLATE FOR SCHOOL YEAR 2023-2024 FOR TEACHER 1 TO TEACHER 3
RPMS TEMPLATE FOR SCHOOL YEAR 2023-2024 FOR TEACHER 1 TO TEACHER 3RPMS TEMPLATE FOR SCHOOL YEAR 2023-2024 FOR TEACHER 1 TO TEACHER 3
RPMS TEMPLATE FOR SCHOOL YEAR 2023-2024 FOR TEACHER 1 TO TEACHER 3
IreneSebastianRueco1
 
South African Journal of Science: Writing with integrity workshop (2024)
South African Journal of Science: Writing with integrity workshop (2024)South African Journal of Science: Writing with integrity workshop (2024)
South African Journal of Science: Writing with integrity workshop (2024)
Academy of Science of South Africa
 
clinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdfclinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdf
Priyankaranawat4
 
BBR 2024 Summer Sessions Interview Training
BBR  2024 Summer Sessions Interview TrainingBBR  2024 Summer Sessions Interview Training
BBR 2024 Summer Sessions Interview Training
Katrina Pritchard
 
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdfANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
Priyankaranawat4
 
Main Java[All of the Base Concepts}.docx
Main Java[All of the Base Concepts}.docxMain Java[All of the Base Concepts}.docx
Main Java[All of the Base Concepts}.docx
adhitya5119
 

Recently uploaded (20)

Community pharmacy- Social and preventive pharmacy UNIT 5
Community pharmacy- Social and preventive pharmacy UNIT 5Community pharmacy- Social and preventive pharmacy UNIT 5
Community pharmacy- Social and preventive pharmacy UNIT 5
 
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
 
PCOS corelations and management through Ayurveda.
PCOS corelations and management through Ayurveda.PCOS corelations and management through Ayurveda.
PCOS corelations and management through Ayurveda.
 
The simplified electron and muon model, Oscillating Spacetime: The Foundation...
The simplified electron and muon model, Oscillating Spacetime: The Foundation...The simplified electron and muon model, Oscillating Spacetime: The Foundation...
The simplified electron and muon model, Oscillating Spacetime: The Foundation...
 
Chapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.pptxChapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.pptx
 
The basics of sentences session 6pptx.pptx
The basics of sentences session 6pptx.pptxThe basics of sentences session 6pptx.pptx
The basics of sentences session 6pptx.pptx
 
Cognitive Development Adolescence Psychology
Cognitive Development Adolescence PsychologyCognitive Development Adolescence Psychology
Cognitive Development Adolescence Psychology
 
How to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP ModuleHow to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP Module
 
Walmart Business+ and Spark Good for Nonprofits.pdf
Walmart Business+ and Spark Good for Nonprofits.pdfWalmart Business+ and Spark Good for Nonprofits.pdf
Walmart Business+ and Spark Good for Nonprofits.pdf
 
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptxC1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
 
Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...
Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...
Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...
 
How to Fix the Import Error in the Odoo 17
How to Fix the Import Error in the Odoo 17How to Fix the Import Error in the Odoo 17
How to Fix the Import Error in the Odoo 17
 
Executive Directors Chat Leveraging AI for Diversity, Equity, and Inclusion
Executive Directors Chat  Leveraging AI for Diversity, Equity, and InclusionExecutive Directors Chat  Leveraging AI for Diversity, Equity, and Inclusion
Executive Directors Chat Leveraging AI for Diversity, Equity, and Inclusion
 
writing about opinions about Australia the movie
writing about opinions about Australia the moviewriting about opinions about Australia the movie
writing about opinions about Australia the movie
 
RPMS TEMPLATE FOR SCHOOL YEAR 2023-2024 FOR TEACHER 1 TO TEACHER 3
RPMS TEMPLATE FOR SCHOOL YEAR 2023-2024 FOR TEACHER 1 TO TEACHER 3RPMS TEMPLATE FOR SCHOOL YEAR 2023-2024 FOR TEACHER 1 TO TEACHER 3
RPMS TEMPLATE FOR SCHOOL YEAR 2023-2024 FOR TEACHER 1 TO TEACHER 3
 
South African Journal of Science: Writing with integrity workshop (2024)
South African Journal of Science: Writing with integrity workshop (2024)South African Journal of Science: Writing with integrity workshop (2024)
South African Journal of Science: Writing with integrity workshop (2024)
 
clinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdfclinical examination of hip joint (1).pdf
clinical examination of hip joint (1).pdf
 
BBR 2024 Summer Sessions Interview Training
BBR  2024 Summer Sessions Interview TrainingBBR  2024 Summer Sessions Interview Training
BBR 2024 Summer Sessions Interview Training
 
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdfANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
 
Main Java[All of the Base Concepts}.docx
Main Java[All of the Base Concepts}.docxMain Java[All of the Base Concepts}.docx
Main Java[All of the Base Concepts}.docx
 

a. Create an arbitrary class without any attributes and methods. b. W.pdf

  • 1. a. Create an arbitrary class without any attributes and methods. b. Write a class named PLANETS, which should have the following data attributes: - name (for the name of the planet) - diameter (for the diameter of the planet) - distance (for the distance from sun of the planet) - length (for the length of year of the planet) c. Inside the class PLANET, define a method called number_of_moons () which return a message including the planet name and number of moons in that planet with the default value 0 . (Hint: number of moons is the method input). d. Create a child class Earth that will inherit all of the variables and methods of the PLANET class. e. Create an object from child class Earth that will inherit all of the variables and methods of the parent Vehicle class and display it. Expected Output: Planet Name: Venus Planet Diameter (miles): 7520 Planet distance (million miles) : 67 Planet length of year (days): 225