SlideShare a Scribd company logo
1 of 1
Download to read offline
Part I: Use array of objects DS to solve the following problem: 1. Write a program that creates a
class named Person. The person class has: id, name, age, gender M/F (Male or Female), and
toString 0 that returns information of a person. 2. Declare and create an array of 10 objects. Cal it
people. 3. Store 10 Persons into the people array. 4. Print a report of each person in the people
array (his/her id, name, age, and gender). 5. Declare and create another two arrays of objects.
The first one called female the second one called male. 6. Separate the persons stored in the
people array into the new two arrays according to the gender (first array for Male category and
second array for Female category). 7. Print a report for each person in the new two arrays.

More Related Content

More from amansarawgi1

Pcond the toonerenenty1. Record the issuance of the $15,000 note p.pdf
 Pcond the toonerenenty1. Record the issuance of the $15,000 note p.pdf Pcond the toonerenenty1. Record the issuance of the $15,000 note p.pdf
Pcond the toonerenenty1. Record the issuance of the $15,000 note p.pdfamansarawgi1
 
Problem 2 (20 marks) Inequality and growth in living standards among .pdf
 Problem 2 (20 marks) Inequality and growth in living standards among .pdf Problem 2 (20 marks) Inequality and growth in living standards among .pdf
Problem 2 (20 marks) Inequality and growth in living standards among .pdfamansarawgi1
 
Part 4 Case Study (7 marks) New payroll tax in Lebanon What it will.pdf
 Part 4 Case Study (7 marks) New payroll tax in Lebanon What it will.pdf Part 4 Case Study (7 marks) New payroll tax in Lebanon What it will.pdf
Part 4 Case Study (7 marks) New payroll tax in Lebanon What it will.pdfamansarawgi1
 
Problem 3 (2 points) Suppose an investor can get a return of 7.25 o.pdf
 Problem 3 (2 points) Suppose an investor can get a return of 7.25 o.pdf Problem 3 (2 points) Suppose an investor can get a return of 7.25 o.pdf
Problem 3 (2 points) Suppose an investor can get a return of 7.25 o.pdfamansarawgi1
 
Part 2 Executive Summary Submit a Word document summariaing your ana.pdf
 Part 2 Executive Summary Submit a Word document summariaing your ana.pdf Part 2 Executive Summary Submit a Word document summariaing your ana.pdf
Part 2 Executive Summary Submit a Word document summariaing your ana.pdfamansarawgi1
 
Presented below is information related to Oriole Co., owned by D. Bro.pdf
 Presented below is information related to Oriole Co., owned by D. Bro.pdf Presented below is information related to Oriole Co., owned by D. Bro.pdf
Presented below is information related to Oriole Co., owned by D. Bro.pdfamansarawgi1
 
Part 2 - Fill in the Network Mapping Table (10 Points) For this part .pdf
 Part 2 - Fill in the Network Mapping Table (10 Points) For this part .pdf Part 2 - Fill in the Network Mapping Table (10 Points) For this part .pdf
Part 2 - Fill in the Network Mapping Table (10 Points) For this part .pdfamansarawgi1
 
Problem 2 (4.5 points) Consider a bond with the following feature. A.pdf
 Problem 2 (4.5 points) Consider a bond with the following feature. A.pdf Problem 2 (4.5 points) Consider a bond with the following feature. A.pdf
Problem 2 (4.5 points) Consider a bond with the following feature. A.pdfamansarawgi1
 
Preprocessor directives always begin with the hash symbol (#) and .pdf
 Preprocessor directives always begin with the hash symbol (#) and .pdf Preprocessor directives always begin with the hash symbol (#) and .pdf
Preprocessor directives always begin with the hash symbol (#) and .pdfamansarawgi1
 
Problem 1. Let X1,�,Xn be independent Gamma(,1) random variables. (1.pdf
 Problem 1. Let X1,�,Xn be independent Gamma(,1) random variables. (1.pdf Problem 1. Let X1,�,Xn be independent Gamma(,1) random variables. (1.pdf
Problem 1. Let X1,�,Xn be independent Gamma(,1) random variables. (1.pdfamansarawgi1
 
Problem 1 [10 points]. [Refer DDCA 6.3]. Review the syntax for below .pdf
 Problem 1 [10 points]. [Refer DDCA 6.3]. Review the syntax for below .pdf Problem 1 [10 points]. [Refer DDCA 6.3]. Review the syntax for below .pdf
Problem 1 [10 points]. [Refer DDCA 6.3]. Review the syntax for below .pdfamansarawgi1
 
Problem 1 (20) marks) The scheme below shows causal relationships amo.pdf
 Problem 1 (20) marks) The scheme below shows causal relationships amo.pdf Problem 1 (20) marks) The scheme below shows causal relationships amo.pdf
Problem 1 (20) marks) The scheme below shows causal relationships amo.pdfamansarawgi1
 
Paity has just completed her second semestor in colege. Sho eamed a g.pdf
 Paity has just completed her second semestor in colege. Sho eamed a g.pdf Paity has just completed her second semestor in colege. Sho eamed a g.pdf
Paity has just completed her second semestor in colege. Sho eamed a g.pdfamansarawgi1
 
probaliity far each of the cimple ecents in the uample space. (Po.pdf
 probaliity far each of the cimple ecents in the uample space. (Po.pdf probaliity far each of the cimple ecents in the uample space. (Po.pdf
probaliity far each of the cimple ecents in the uample space. (Po.pdfamansarawgi1
 
Prime numbers. Write a program that prompts the user for an integer a.pdf
 Prime numbers. Write a program that prompts the user for an integer a.pdf Prime numbers. Write a program that prompts the user for an integer a.pdf
Prime numbers. Write a program that prompts the user for an integer a.pdfamansarawgi1
 
Privatization is a form of Government Regulation that serves to stren.pdf
 Privatization is a form of Government Regulation that serves to stren.pdf Privatization is a form of Government Regulation that serves to stren.pdf
Privatization is a form of Government Regulation that serves to stren.pdfamansarawgi1
 
Presented below are variable costing income statements for Sheridan C.pdf
 Presented below are variable costing income statements for Sheridan C.pdf Presented below are variable costing income statements for Sheridan C.pdf
Presented below are variable costing income statements for Sheridan C.pdfamansarawgi1
 
Pre-lecture quiz (Question 4) Which of the following is the major typ.pdf
 Pre-lecture quiz (Question 4) Which of the following is the major typ.pdf Pre-lecture quiz (Question 4) Which of the following is the major typ.pdf
Pre-lecture quiz (Question 4) Which of the following is the major typ.pdfamansarawgi1
 
Pregunta 1 Escribir en el teclado o escribir 100 palabras p.pdf
 Pregunta 1 Escribir en el teclado o escribir 100 palabras p.pdf Pregunta 1 Escribir en el teclado o escribir 100 palabras p.pdf
Pregunta 1 Escribir en el teclado o escribir 100 palabras p.pdfamansarawgi1
 
Pereetual iwrentery using firo The foliowiry units of a barticular in.pdf
 Pereetual iwrentery using firo The foliowiry units of a barticular in.pdf Pereetual iwrentery using firo The foliowiry units of a barticular in.pdf
Pereetual iwrentery using firo The foliowiry units of a barticular in.pdfamansarawgi1
 

More from amansarawgi1 (20)

Pcond the toonerenenty1. Record the issuance of the $15,000 note p.pdf
 Pcond the toonerenenty1. Record the issuance of the $15,000 note p.pdf Pcond the toonerenenty1. Record the issuance of the $15,000 note p.pdf
Pcond the toonerenenty1. Record the issuance of the $15,000 note p.pdf
 
Problem 2 (20 marks) Inequality and growth in living standards among .pdf
 Problem 2 (20 marks) Inequality and growth in living standards among .pdf Problem 2 (20 marks) Inequality and growth in living standards among .pdf
Problem 2 (20 marks) Inequality and growth in living standards among .pdf
 
Part 4 Case Study (7 marks) New payroll tax in Lebanon What it will.pdf
 Part 4 Case Study (7 marks) New payroll tax in Lebanon What it will.pdf Part 4 Case Study (7 marks) New payroll tax in Lebanon What it will.pdf
Part 4 Case Study (7 marks) New payroll tax in Lebanon What it will.pdf
 
Problem 3 (2 points) Suppose an investor can get a return of 7.25 o.pdf
 Problem 3 (2 points) Suppose an investor can get a return of 7.25 o.pdf Problem 3 (2 points) Suppose an investor can get a return of 7.25 o.pdf
Problem 3 (2 points) Suppose an investor can get a return of 7.25 o.pdf
 
Part 2 Executive Summary Submit a Word document summariaing your ana.pdf
 Part 2 Executive Summary Submit a Word document summariaing your ana.pdf Part 2 Executive Summary Submit a Word document summariaing your ana.pdf
Part 2 Executive Summary Submit a Word document summariaing your ana.pdf
 
Presented below is information related to Oriole Co., owned by D. Bro.pdf
 Presented below is information related to Oriole Co., owned by D. Bro.pdf Presented below is information related to Oriole Co., owned by D. Bro.pdf
Presented below is information related to Oriole Co., owned by D. Bro.pdf
 
Part 2 - Fill in the Network Mapping Table (10 Points) For this part .pdf
 Part 2 - Fill in the Network Mapping Table (10 Points) For this part .pdf Part 2 - Fill in the Network Mapping Table (10 Points) For this part .pdf
Part 2 - Fill in the Network Mapping Table (10 Points) For this part .pdf
 
Problem 2 (4.5 points) Consider a bond with the following feature. A.pdf
 Problem 2 (4.5 points) Consider a bond with the following feature. A.pdf Problem 2 (4.5 points) Consider a bond with the following feature. A.pdf
Problem 2 (4.5 points) Consider a bond with the following feature. A.pdf
 
Preprocessor directives always begin with the hash symbol (#) and .pdf
 Preprocessor directives always begin with the hash symbol (#) and .pdf Preprocessor directives always begin with the hash symbol (#) and .pdf
Preprocessor directives always begin with the hash symbol (#) and .pdf
 
Problem 1. Let X1,�,Xn be independent Gamma(,1) random variables. (1.pdf
 Problem 1. Let X1,�,Xn be independent Gamma(,1) random variables. (1.pdf Problem 1. Let X1,�,Xn be independent Gamma(,1) random variables. (1.pdf
Problem 1. Let X1,�,Xn be independent Gamma(,1) random variables. (1.pdf
 
Problem 1 [10 points]. [Refer DDCA 6.3]. Review the syntax for below .pdf
 Problem 1 [10 points]. [Refer DDCA 6.3]. Review the syntax for below .pdf Problem 1 [10 points]. [Refer DDCA 6.3]. Review the syntax for below .pdf
Problem 1 [10 points]. [Refer DDCA 6.3]. Review the syntax for below .pdf
 
Problem 1 (20) marks) The scheme below shows causal relationships amo.pdf
 Problem 1 (20) marks) The scheme below shows causal relationships amo.pdf Problem 1 (20) marks) The scheme below shows causal relationships amo.pdf
Problem 1 (20) marks) The scheme below shows causal relationships amo.pdf
 
Paity has just completed her second semestor in colege. Sho eamed a g.pdf
 Paity has just completed her second semestor in colege. Sho eamed a g.pdf Paity has just completed her second semestor in colege. Sho eamed a g.pdf
Paity has just completed her second semestor in colege. Sho eamed a g.pdf
 
probaliity far each of the cimple ecents in the uample space. (Po.pdf
 probaliity far each of the cimple ecents in the uample space. (Po.pdf probaliity far each of the cimple ecents in the uample space. (Po.pdf
probaliity far each of the cimple ecents in the uample space. (Po.pdf
 
Prime numbers. Write a program that prompts the user for an integer a.pdf
 Prime numbers. Write a program that prompts the user for an integer a.pdf Prime numbers. Write a program that prompts the user for an integer a.pdf
Prime numbers. Write a program that prompts the user for an integer a.pdf
 
Privatization is a form of Government Regulation that serves to stren.pdf
 Privatization is a form of Government Regulation that serves to stren.pdf Privatization is a form of Government Regulation that serves to stren.pdf
Privatization is a form of Government Regulation that serves to stren.pdf
 
Presented below are variable costing income statements for Sheridan C.pdf
 Presented below are variable costing income statements for Sheridan C.pdf Presented below are variable costing income statements for Sheridan C.pdf
Presented below are variable costing income statements for Sheridan C.pdf
 
Pre-lecture quiz (Question 4) Which of the following is the major typ.pdf
 Pre-lecture quiz (Question 4) Which of the following is the major typ.pdf Pre-lecture quiz (Question 4) Which of the following is the major typ.pdf
Pre-lecture quiz (Question 4) Which of the following is the major typ.pdf
 
Pregunta 1 Escribir en el teclado o escribir 100 palabras p.pdf
 Pregunta 1 Escribir en el teclado o escribir 100 palabras p.pdf Pregunta 1 Escribir en el teclado o escribir 100 palabras p.pdf
Pregunta 1 Escribir en el teclado o escribir 100 palabras p.pdf
 
Pereetual iwrentery using firo The foliowiry units of a barticular in.pdf
 Pereetual iwrentery using firo The foliowiry units of a barticular in.pdf Pereetual iwrentery using firo The foliowiry units of a barticular in.pdf
Pereetual iwrentery using firo The foliowiry units of a barticular in.pdf
 

Recently uploaded

Class 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfClass 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfakmcokerachita
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfSumit Tiwari
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxmanuelaromero2013
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentInMediaRes1
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Sapana Sha
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionSafetyChain Software
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesFatimaKhan178732
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformChameera Dedduwage
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...EduSkills OECD
 
The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13Steve Thomason
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon AUnboundStockton
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactdawncurless
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxiammrhaywood
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)eniolaolutunde
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdfssuser54595a
 

Recently uploaded (20)

Class 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfClass 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdf
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptx
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media Component
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory Inspection
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and Actinides
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy Reform
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13
 
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon A
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
 

Part I Use array of objects DS to solve the following problem 1. Wr.pdf

  • 1. Part I: Use array of objects DS to solve the following problem: 1. Write a program that creates a class named Person. The person class has: id, name, age, gender M/F (Male or Female), and toString 0 that returns information of a person. 2. Declare and create an array of 10 objects. Cal it people. 3. Store 10 Persons into the people array. 4. Print a report of each person in the people array (his/her id, name, age, and gender). 5. Declare and create another two arrays of objects. The first one called female the second one called male. 6. Separate the persons stored in the people array into the new two arrays according to the gender (first array for Male category and second array for Female category). 7. Print a report for each person in the new two arrays.