By: Sunil Sahu , Author SelfLearn Java Introduction: Internship Is Not a Certificate – It Is Your Career Foundation For BE and MCA students, an internship is not a ritual, not a college formality, and definitely not “just another certificate.” It is the first real entry into the professional IT world. Unfortunately, thousands of talented students destroy their career foundation every year due to wrong internship choices, casual behavior, and misleading college systems. This article exposes: The most dangerous internship mistakes students make The shocking truth of college-based internships And the right way to use the final 6 months for real job success Mistake #1: Treating Internship as a Formality Many students believe: “Internship sirf certificate ke liye hoti hai.” This is the first professional blunder. Companies treat internships as trial employment. Your performance decides: Job offers Salary growth Industry recommendations An internship is your fir...
A Stream is a series of objects. Source of a stream is an Array, Collection, or Other I/O source. A Stream does not store data, it does only intermediate operations. It can filter and manipulate the elements of its source. Streams are lazy, the source and intermediate operations do nothing until objects are needed by the terminal operation. Steams APIs are contained by java.util.stream package. A water filter is the best example of streams. It processes the water stream. It has multiple filters that work one after another. Filters do purification, reverse osmosis, refinement of water, and produce drinking water. The water filter does not store the water it simply processes the water stream. Getting Started 1. Create a Stream and print all elements Let's create a stream from a collection and print all its elements. The following example creates a Stream from the list collection and prints all elements of the collection using its forEa...
Java 8 Features 1. forEach() forEach(): method is used to iterate the elements. It takes a single parameter. It is a default method of the Iterable interface. We can pass lambda expressions as an argument. public class ForEachExample { public static void main(String[] args) { List<String> list = new ArrayList<String>(); list.add("One"); list.add("Two); list.add("Three"); list.add("Four"); list.forEach(li -> System.out.println(li)); } } 2. Functional Interfaces and Lambda Expressions Functional Interface The Functional interface contains only one abstract method and also contains a number of default and static methods. Functional Interface is annotated by @FunctionalInterface annotation, it ensures that ...