From d0758ab398f584063d69e476d06fddf139625379 Mon Sep 17 00:00:00 2001 From: SweeneyNew <44316108+SweeneyNew@users.noreply.github.com> Date: Fri, 7 Dec 2018 11:58:11 +0300 Subject: [PATCH] Code Description (#24164) "import java.util.ArrayList;" is a java code. It should be declared in "code theme". People may miss the "import package" code part since it is not discriminated from the other parts as a code part. If they miss the whole code will complain just because of this simple mistake. This way people wouldn't miss the code to import the package. --- guide/english/java/arraylist/index.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/guide/english/java/arraylist/index.md b/guide/english/java/arraylist/index.md index f700a3b517..e200b9ffd5 100644 --- a/guide/english/java/arraylist/index.md +++ b/guide/english/java/arraylist/index.md @@ -6,7 +6,10 @@ title: ArrayList The *Collection framework* consists of all interfaces and classes that can hold a set of values (similar to [arrays](https://docs.oracle.com/javase/tutorial/java/nutsandbolts/arrays.html)). **ArrayList** is a class that is in this hierarchy and known as a _**Collection object**_. It implements the *List* interface which in turn implements the *Collection* interface. This *Collection* interface can be found in the `java.util` package. You will need to import this package. - ```java import java.util.ArrayList; //is more efficient than importing all of java.util``` + ```java + import java.util.ArrayList; // is more efficient than importing all of java.util + ``` + Always import the most specific package in order to save memory size and performance time.