SlideShare a Scribd company logo
1 of 1
Download to read offline
Design your own List ADT named StringList to provide the following operations on a list
object: 1. add (void add(String item) 2. remove (void remove(int index) and void
remove(String item)) 3. size() (int size()) 4. isEmpty (boolean isEmpty() ) 5. indexOf (int
indexOf(String item)) 6. hasItem (boolean hasItem(String item) ) 7. isFull (boolean isFull() ) 8.
getByIndex (String getByIndex(int index)) 9. toString (String toString(), which returns items in
the list in the format as specified below: [Bottle water, Turkey, Oil, Banana] You
are required to use array to implement this ADT. Array only, no other data structures can be used
to implement the structure.
Solution
public class ADT
{
String a[] = new String[1000];
int len=0;
void add(String s)//add item to array
{
a[len++]=s;
System.out.println(" data added to array ");
}
void remove(String s)//remove item from array
{
int i,j;
i = indexOf(s);
if(i!=-1){
for(j=i;j

More Related Content

Similar to Design your own List ADT named StringList to provide the following .pdf

2.(Sorted list array implementation)This sorted list ADT discussed .pdf
2.(Sorted list array implementation)This sorted list ADT discussed .pdf2.(Sorted list array implementation)This sorted list ADT discussed .pdf
2.(Sorted list array implementation)This sorted list ADT discussed .pdfarshin9
 
import java.util.ArrayList; import java.util.List;public class S.pdf
import java.util.ArrayList; import java.util.List;public class S.pdfimport java.util.ArrayList; import java.util.List;public class S.pdf
import java.util.ArrayList; import java.util.List;public class S.pdfanupamele
 
Java ArrayList Tutorial | Edureka
Java ArrayList Tutorial | EdurekaJava ArrayList Tutorial | Edureka
Java ArrayList Tutorial | EdurekaEdureka!
 
Hi,I have added the methods and main class as per your requirement.pdf
Hi,I have added the methods and main class as per your requirement.pdfHi,I have added the methods and main class as per your requirement.pdf
Hi,I have added the methods and main class as per your requirement.pdfannaelctronics
 
Lecture 18Dynamic Data Structures and Generics (II).docx
Lecture 18Dynamic Data Structures and Generics (II).docxLecture 18Dynamic Data Structures and Generics (II).docx
Lecture 18Dynamic Data Structures and Generics (II).docxSHIVA101531
 
ReversePoem.java ---------------------------------- public cl.pdf
ReversePoem.java ---------------------------------- public cl.pdfReversePoem.java ---------------------------------- public cl.pdf
ReversePoem.java ---------------------------------- public cl.pdfravikapoorindia
 
I need help creating a parametized JUnit test case for the following.pdf
I need help creating a parametized JUnit test case for the following.pdfI need help creating a parametized JUnit test case for the following.pdf
I need help creating a parametized JUnit test case for the following.pdffonecomp
 
write a program that given a list of 20 integers, sorts them accordi.pdf
write a program that given a list of 20 integers, sorts them accordi.pdfwrite a program that given a list of 20 integers, sorts them accordi.pdf
write a program that given a list of 20 integers, sorts them accordi.pdfarmcomputers
 
import java.util.;public class FirstChars {    public static vo.pdf
import java.util.;public class FirstChars {    public static vo.pdfimport java.util.;public class FirstChars {    public static vo.pdf
import java.util.;public class FirstChars {    public static vo.pdfapoorvikamobileworld
 
Given Starter Fileimport java.util.Arrays; Encapsulates.pdf
Given Starter Fileimport java.util.Arrays;   Encapsulates.pdfGiven Starter Fileimport java.util.Arrays;   Encapsulates.pdf
Given Starter Fileimport java.util.Arrays; Encapsulates.pdfarchanaemporium
 
Everything needs to be according to the instructions- thank you! SUPPO.pdf
Everything needs to be according to the instructions- thank you! SUPPO.pdfEverything needs to be according to the instructions- thank you! SUPPO.pdf
Everything needs to be according to the instructions- thank you! SUPPO.pdffirstchoiceajmer
 
Array based based implementation of the List ADT It uses an array o.pdf
Array based based implementation of the List ADT It uses an array o.pdfArray based based implementation of the List ADT It uses an array o.pdf
Array based based implementation of the List ADT It uses an array o.pdfanithacells
 
week4_srcArrayMethods.javaweek4_srcArrayMethods.javapackage ed.docx
week4_srcArrayMethods.javaweek4_srcArrayMethods.javapackage ed.docxweek4_srcArrayMethods.javaweek4_srcArrayMethods.javapackage ed.docx
week4_srcArrayMethods.javaweek4_srcArrayMethods.javapackage ed.docxalanfhall8953
 
Question In C Programming In mathematics, a set is a colle...Sav.pdf
Question In C Programming In mathematics, a set is a colle...Sav.pdfQuestion In C Programming In mathematics, a set is a colle...Sav.pdf
Question In C Programming In mathematics, a set is a colle...Sav.pdfarihantcomp1008
 
Create a Queue class that implements a queue abstraction. A queue is.docx
Create a Queue class that implements a queue abstraction. A queue is.docxCreate a Queue class that implements a queue abstraction. A queue is.docx
Create a Queue class that implements a queue abstraction. A queue is.docxrajahchelsey
 
Implementation The starter code includes List.java. You should not c.pdf
Implementation The starter code includes List.java. You should not c.pdfImplementation The starter code includes List.java. You should not c.pdf
Implementation The starter code includes List.java. You should not c.pdfmaheshkumar12354
 
Aj unit2 notesjavadatastructures
Aj unit2 notesjavadatastructuresAj unit2 notesjavadatastructures
Aj unit2 notesjavadatastructuresArthik Daniel
 
Write a program that will test a name) method no sorting routine from.docx
 Write a program that will test a name) method no sorting routine from.docx Write a program that will test a name) method no sorting routine from.docx
Write a program that will test a name) method no sorting routine from.docxajoy21
 

Similar to Design your own List ADT named StringList to provide the following .pdf (20)

2.(Sorted list array implementation)This sorted list ADT discussed .pdf
2.(Sorted list array implementation)This sorted list ADT discussed .pdf2.(Sorted list array implementation)This sorted list ADT discussed .pdf
2.(Sorted list array implementation)This sorted list ADT discussed .pdf
 
import java.util.ArrayList; import java.util.List;public class S.pdf
import java.util.ArrayList; import java.util.List;public class S.pdfimport java.util.ArrayList; import java.util.List;public class S.pdf
import java.util.ArrayList; import java.util.List;public class S.pdf
 
Java ArrayList Tutorial | Edureka
Java ArrayList Tutorial | EdurekaJava ArrayList Tutorial | Edureka
Java ArrayList Tutorial | Edureka
 
Hi,I have added the methods and main class as per your requirement.pdf
Hi,I have added the methods and main class as per your requirement.pdfHi,I have added the methods and main class as per your requirement.pdf
Hi,I have added the methods and main class as per your requirement.pdf
 
Oop lecture7
Oop lecture7Oop lecture7
Oop lecture7
 
6_Array.pptx
6_Array.pptx6_Array.pptx
6_Array.pptx
 
Lecture 18Dynamic Data Structures and Generics (II).docx
Lecture 18Dynamic Data Structures and Generics (II).docxLecture 18Dynamic Data Structures and Generics (II).docx
Lecture 18Dynamic Data Structures and Generics (II).docx
 
ReversePoem.java ---------------------------------- public cl.pdf
ReversePoem.java ---------------------------------- public cl.pdfReversePoem.java ---------------------------------- public cl.pdf
ReversePoem.java ---------------------------------- public cl.pdf
 
I need help creating a parametized JUnit test case for the following.pdf
I need help creating a parametized JUnit test case for the following.pdfI need help creating a parametized JUnit test case for the following.pdf
I need help creating a parametized JUnit test case for the following.pdf
 
write a program that given a list of 20 integers, sorts them accordi.pdf
write a program that given a list of 20 integers, sorts them accordi.pdfwrite a program that given a list of 20 integers, sorts them accordi.pdf
write a program that given a list of 20 integers, sorts them accordi.pdf
 
import java.util.;public class FirstChars {    public static vo.pdf
import java.util.;public class FirstChars {    public static vo.pdfimport java.util.;public class FirstChars {    public static vo.pdf
import java.util.;public class FirstChars {    public static vo.pdf
 
Given Starter Fileimport java.util.Arrays; Encapsulates.pdf
Given Starter Fileimport java.util.Arrays;   Encapsulates.pdfGiven Starter Fileimport java.util.Arrays;   Encapsulates.pdf
Given Starter Fileimport java.util.Arrays; Encapsulates.pdf
 
Everything needs to be according to the instructions- thank you! SUPPO.pdf
Everything needs to be according to the instructions- thank you! SUPPO.pdfEverything needs to be according to the instructions- thank you! SUPPO.pdf
Everything needs to be according to the instructions- thank you! SUPPO.pdf
 
Array based based implementation of the List ADT It uses an array o.pdf
Array based based implementation of the List ADT It uses an array o.pdfArray based based implementation of the List ADT It uses an array o.pdf
Array based based implementation of the List ADT It uses an array o.pdf
 
week4_srcArrayMethods.javaweek4_srcArrayMethods.javapackage ed.docx
week4_srcArrayMethods.javaweek4_srcArrayMethods.javapackage ed.docxweek4_srcArrayMethods.javaweek4_srcArrayMethods.javapackage ed.docx
week4_srcArrayMethods.javaweek4_srcArrayMethods.javapackage ed.docx
 
Question In C Programming In mathematics, a set is a colle...Sav.pdf
Question In C Programming In mathematics, a set is a colle...Sav.pdfQuestion In C Programming In mathematics, a set is a colle...Sav.pdf
Question In C Programming In mathematics, a set is a colle...Sav.pdf
 
Create a Queue class that implements a queue abstraction. A queue is.docx
Create a Queue class that implements a queue abstraction. A queue is.docxCreate a Queue class that implements a queue abstraction. A queue is.docx
Create a Queue class that implements a queue abstraction. A queue is.docx
 
Implementation The starter code includes List.java. You should not c.pdf
Implementation The starter code includes List.java. You should not c.pdfImplementation The starter code includes List.java. You should not c.pdf
Implementation The starter code includes List.java. You should not c.pdf
 
Aj unit2 notesjavadatastructures
Aj unit2 notesjavadatastructuresAj unit2 notesjavadatastructures
Aj unit2 notesjavadatastructures
 
Write a program that will test a name) method no sorting routine from.docx
 Write a program that will test a name) method no sorting routine from.docx Write a program that will test a name) method no sorting routine from.docx
Write a program that will test a name) method no sorting routine from.docx
 

More from prajeetjain

f the probabilities of having a male or female child are both 0.50, .pdf
f the probabilities of having a male or female child are both 0.50, .pdff the probabilities of having a male or female child are both 0.50, .pdf
f the probabilities of having a male or female child are both 0.50, .pdfprajeetjain
 
Explain how the development of technology is a system of events and .pdf
Explain how the development of technology is a system of events and .pdfExplain how the development of technology is a system of events and .pdf
Explain how the development of technology is a system of events and .pdfprajeetjain
 
Distinguish between ectothermic and endothermic animals. Give at leas.pdf
Distinguish between ectothermic and endothermic animals. Give at leas.pdfDistinguish between ectothermic and endothermic animals. Give at leas.pdf
Distinguish between ectothermic and endothermic animals. Give at leas.pdfprajeetjain
 
Economics Today Identify the various taxes government utilizes to fu.pdf
Economics Today Identify the various taxes government utilizes to fu.pdfEconomics Today Identify the various taxes government utilizes to fu.pdf
Economics Today Identify the various taxes government utilizes to fu.pdfprajeetjain
 
Describe Gross Domestic Product (GDP), do you think it is helpful in.pdf
Describe Gross Domestic Product (GDP), do you think it is helpful in.pdfDescribe Gross Domestic Product (GDP), do you think it is helpful in.pdf
Describe Gross Domestic Product (GDP), do you think it is helpful in.pdfprajeetjain
 
Chapter 14 Managing Projects 569 A Shaky Start for Healthcare.Gov CAS.pdf
Chapter 14 Managing Projects 569 A Shaky Start for Healthcare.Gov CAS.pdfChapter 14 Managing Projects 569 A Shaky Start for Healthcare.Gov CAS.pdf
Chapter 14 Managing Projects 569 A Shaky Start for Healthcare.Gov CAS.pdfprajeetjain
 
Anwar dresses for a cold fall day and steps outside to find it sunny.pdf
Anwar dresses for a cold fall day and steps outside to find it sunny.pdfAnwar dresses for a cold fall day and steps outside to find it sunny.pdf
Anwar dresses for a cold fall day and steps outside to find it sunny.pdfprajeetjain
 
Briefly describe how the development of steam powered ships transfor.pdf
Briefly describe how the development of steam powered ships transfor.pdfBriefly describe how the development of steam powered ships transfor.pdf
Briefly describe how the development of steam powered ships transfor.pdfprajeetjain
 
A) compare three signs of schizophrenia with three signs of depr.pdf
A) compare three signs of schizophrenia with three signs of depr.pdfA) compare three signs of schizophrenia with three signs of depr.pdf
A) compare three signs of schizophrenia with three signs of depr.pdfprajeetjain
 
According to Mendelian genetics, a recessive trait will appear in an .pdf
According to Mendelian genetics, a recessive trait will appear in an .pdfAccording to Mendelian genetics, a recessive trait will appear in an .pdf
According to Mendelian genetics, a recessive trait will appear in an .pdfprajeetjain
 
Biliverdin and bilirubin are pigments that form during the breakdow.pdf
Biliverdin and bilirubin are  pigments that form during the breakdow.pdfBiliverdin and bilirubin are  pigments that form during the breakdow.pdf
Biliverdin and bilirubin are pigments that form during the breakdow.pdfprajeetjain
 
4b. Two families of sloths exist commonly in Central and South Americ.pdf
4b. Two families of sloths exist commonly in Central and South Americ.pdf4b. Two families of sloths exist commonly in Central and South Americ.pdf
4b. Two families of sloths exist commonly in Central and South Americ.pdfprajeetjain
 
2 Answer the following. Describe how you would expect residual (a) so.pdf
2 Answer the following. Describe how you would expect residual (a) so.pdf2 Answer the following. Describe how you would expect residual (a) so.pdf
2 Answer the following. Describe how you would expect residual (a) so.pdfprajeetjain
 
Write a program (PYTHON) that allows the user to add, delete and org.pdf
Write a program (PYTHON) that allows the user to add, delete and org.pdfWrite a program (PYTHON) that allows the user to add, delete and org.pdf
Write a program (PYTHON) that allows the user to add, delete and org.pdfprajeetjain
 
Write out the set P, where P is the set of even natural numbers betw.pdf
Write out the set P, where P is the set of even natural numbers betw.pdfWrite out the set P, where P is the set of even natural numbers betw.pdf
Write out the set P, where P is the set of even natural numbers betw.pdfprajeetjain
 
Why are R waves (Figure) used to determine heart rate rather than T w.pdf
Why are R waves (Figure) used to determine heart rate rather than T w.pdfWhy are R waves (Figure) used to determine heart rate rather than T w.pdf
Why are R waves (Figure) used to determine heart rate rather than T w.pdfprajeetjain
 
1. The dura mater is composed of which type of connective tissueA.pdf
1. The dura mater is composed of which type of connective tissueA.pdf1. The dura mater is composed of which type of connective tissueA.pdf
1. The dura mater is composed of which type of connective tissueA.pdfprajeetjain
 
What would cause a collision in a hash table Select one a. The pr.pdf
What would cause a collision in a hash table  Select one  a. The pr.pdfWhat would cause a collision in a hash table  Select one  a. The pr.pdf
What would cause a collision in a hash table Select one a. The pr.pdfprajeetjain
 
What risks do Web and database attacks create for an organization.pdf
What risks do Web and database attacks create for an organization.pdfWhat risks do Web and database attacks create for an organization.pdf
What risks do Web and database attacks create for an organization.pdfprajeetjain
 
What is the difference in secretory and co translational pathway in .pdf
What is the difference in secretory and co translational pathway in .pdfWhat is the difference in secretory and co translational pathway in .pdf
What is the difference in secretory and co translational pathway in .pdfprajeetjain
 

More from prajeetjain (20)

f the probabilities of having a male or female child are both 0.50, .pdf
f the probabilities of having a male or female child are both 0.50, .pdff the probabilities of having a male or female child are both 0.50, .pdf
f the probabilities of having a male or female child are both 0.50, .pdf
 
Explain how the development of technology is a system of events and .pdf
Explain how the development of technology is a system of events and .pdfExplain how the development of technology is a system of events and .pdf
Explain how the development of technology is a system of events and .pdf
 
Distinguish between ectothermic and endothermic animals. Give at leas.pdf
Distinguish between ectothermic and endothermic animals. Give at leas.pdfDistinguish between ectothermic and endothermic animals. Give at leas.pdf
Distinguish between ectothermic and endothermic animals. Give at leas.pdf
 
Economics Today Identify the various taxes government utilizes to fu.pdf
Economics Today Identify the various taxes government utilizes to fu.pdfEconomics Today Identify the various taxes government utilizes to fu.pdf
Economics Today Identify the various taxes government utilizes to fu.pdf
 
Describe Gross Domestic Product (GDP), do you think it is helpful in.pdf
Describe Gross Domestic Product (GDP), do you think it is helpful in.pdfDescribe Gross Domestic Product (GDP), do you think it is helpful in.pdf
Describe Gross Domestic Product (GDP), do you think it is helpful in.pdf
 
Chapter 14 Managing Projects 569 A Shaky Start for Healthcare.Gov CAS.pdf
Chapter 14 Managing Projects 569 A Shaky Start for Healthcare.Gov CAS.pdfChapter 14 Managing Projects 569 A Shaky Start for Healthcare.Gov CAS.pdf
Chapter 14 Managing Projects 569 A Shaky Start for Healthcare.Gov CAS.pdf
 
Anwar dresses for a cold fall day and steps outside to find it sunny.pdf
Anwar dresses for a cold fall day and steps outside to find it sunny.pdfAnwar dresses for a cold fall day and steps outside to find it sunny.pdf
Anwar dresses for a cold fall day and steps outside to find it sunny.pdf
 
Briefly describe how the development of steam powered ships transfor.pdf
Briefly describe how the development of steam powered ships transfor.pdfBriefly describe how the development of steam powered ships transfor.pdf
Briefly describe how the development of steam powered ships transfor.pdf
 
A) compare three signs of schizophrenia with three signs of depr.pdf
A) compare three signs of schizophrenia with three signs of depr.pdfA) compare three signs of schizophrenia with three signs of depr.pdf
A) compare three signs of schizophrenia with three signs of depr.pdf
 
According to Mendelian genetics, a recessive trait will appear in an .pdf
According to Mendelian genetics, a recessive trait will appear in an .pdfAccording to Mendelian genetics, a recessive trait will appear in an .pdf
According to Mendelian genetics, a recessive trait will appear in an .pdf
 
Biliverdin and bilirubin are pigments that form during the breakdow.pdf
Biliverdin and bilirubin are  pigments that form during the breakdow.pdfBiliverdin and bilirubin are  pigments that form during the breakdow.pdf
Biliverdin and bilirubin are pigments that form during the breakdow.pdf
 
4b. Two families of sloths exist commonly in Central and South Americ.pdf
4b. Two families of sloths exist commonly in Central and South Americ.pdf4b. Two families of sloths exist commonly in Central and South Americ.pdf
4b. Two families of sloths exist commonly in Central and South Americ.pdf
 
2 Answer the following. Describe how you would expect residual (a) so.pdf
2 Answer the following. Describe how you would expect residual (a) so.pdf2 Answer the following. Describe how you would expect residual (a) so.pdf
2 Answer the following. Describe how you would expect residual (a) so.pdf
 
Write a program (PYTHON) that allows the user to add, delete and org.pdf
Write a program (PYTHON) that allows the user to add, delete and org.pdfWrite a program (PYTHON) that allows the user to add, delete and org.pdf
Write a program (PYTHON) that allows the user to add, delete and org.pdf
 
Write out the set P, where P is the set of even natural numbers betw.pdf
Write out the set P, where P is the set of even natural numbers betw.pdfWrite out the set P, where P is the set of even natural numbers betw.pdf
Write out the set P, where P is the set of even natural numbers betw.pdf
 
Why are R waves (Figure) used to determine heart rate rather than T w.pdf
Why are R waves (Figure) used to determine heart rate rather than T w.pdfWhy are R waves (Figure) used to determine heart rate rather than T w.pdf
Why are R waves (Figure) used to determine heart rate rather than T w.pdf
 
1. The dura mater is composed of which type of connective tissueA.pdf
1. The dura mater is composed of which type of connective tissueA.pdf1. The dura mater is composed of which type of connective tissueA.pdf
1. The dura mater is composed of which type of connective tissueA.pdf
 
What would cause a collision in a hash table Select one a. The pr.pdf
What would cause a collision in a hash table  Select one  a. The pr.pdfWhat would cause a collision in a hash table  Select one  a. The pr.pdf
What would cause a collision in a hash table Select one a. The pr.pdf
 
What risks do Web and database attacks create for an organization.pdf
What risks do Web and database attacks create for an organization.pdfWhat risks do Web and database attacks create for an organization.pdf
What risks do Web and database attacks create for an organization.pdf
 
What is the difference in secretory and co translational pathway in .pdf
What is the difference in secretory and co translational pathway in .pdfWhat is the difference in secretory and co translational pathway in .pdf
What is the difference in secretory and co translational pathway in .pdf
 

Recently uploaded

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
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Celine George
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for BeginnersSabitha Banu
 
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...M56BOOKSTORE PRODUCT/SERVICE
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
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
 
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
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationnomboosow
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxiammrhaywood
 
Biting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdfBiting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdfadityarao40181
 
Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...jaredbarbolino94
 
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,Virag Sontakke
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersSabitha Banu
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxSayali Powar
 
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
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxOH TEIK BIN
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)eniolaolutunde
 
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxHistory Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxsocialsciencegdgrohi
 
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
 

Recently uploaded (20)

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
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for Beginners
 
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
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
 
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 🔝✔️✔️
 
9953330565 Low Rate Call Girls In Rohini Delhi NCR
9953330565 Low Rate Call Girls In Rohini  Delhi NCR9953330565 Low Rate Call Girls In Rohini  Delhi NCR
9953330565 Low Rate Call Girls In Rohini Delhi NCR
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communication
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
 
Biting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdfBiting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdf
 
Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...
 
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginners
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.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
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptx
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxHistory Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
 
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
 

Design your own List ADT named StringList to provide the following .pdf

  • 1. Design your own List ADT named StringList to provide the following operations on a list object: 1. add (void add(String item) 2. remove (void remove(int index) and void remove(String item)) 3. size() (int size()) 4. isEmpty (boolean isEmpty() ) 5. indexOf (int indexOf(String item)) 6. hasItem (boolean hasItem(String item) ) 7. isFull (boolean isFull() ) 8. getByIndex (String getByIndex(int index)) 9. toString (String toString(), which returns items in the list in the format as specified below: [Bottle water, Turkey, Oil, Banana] You are required to use array to implement this ADT. Array only, no other data structures can be used to implement the structure. Solution public class ADT { String a[] = new String[1000]; int len=0; void add(String s)//add item to array { a[len++]=s; System.out.println(" data added to array "); } void remove(String s)//remove item from array { int i,j; i = indexOf(s); if(i!=-1){ for(j=i;j