Created a arrayList to store the data.