What do you want to save?
Add Code snippet
New code examples
-
Java 2021-10-04 17:25:02
arraylist to set java 8
Set<Foo> foo = new HashSet<Foo>(myList); Add solution -
Java 2021-10-02 18:47:06
HashSet Object clone() method in java
import java.util.HashSet; public class HashSetObjectCloneMethodExample { public static void main(String[] args) { HashSet<String> hs = new HashSet<String>(); hs.add("Welcome"); hs.add("hello"); ... Add solution -
C# 2021-09-28 20:38:03
How to Insert or Delete Elements to Collection During Iteration in c#
// one of many possibilities is to use another collection // for other possibilities see: //https://www.techiedelight.com/remove-elements-from-list-while-iterating-csharp/ // or: // https://stackoverflow.com/questions/1582285/how-to-remove-elements-from... Add solution -
Java 2021-09-26 11:34:05
java coding standards for interfaces
It is recommended highly to follow java coding standards. Classnames should start with uppercase letter. Classnames names should be nouns. If Class name is of multiple words then the first letter of inner word must be capital letter. Ex : Employee, Emplo... Add solution -
Java 2021-09-23 23:25:03
Polymorphisim
Polymorphism means objects behave in different forms. ■ It occurs when parent class/interface calls to child class' objects Sub class can never be the reference type of Super Class Object ■ The reference of an object decides what is accessible. ■ Abstr... Add solution -
Java 2021-09-20 14:45:02
Remove duplicate element in an array in java
import java.util.*; public class RemoveDuplicatesFromArrayList { public static void main(String[] args) { List<Integer> numbers = Arrays.asList(1,2,2,2,3,5); System.out.println(numbers); Set<Integer> hashSet = n... Add solution -
Java 2021-09-16 05:56:02
collection types in java
LIST: Can store duplicate values, Keeps the insertion order. It allows multiple null values, Also we can read a certain value by index. - ArrayList not syncronized, array based class - LinkedList not synchronized, doubly linked - Vect... Add solution