Java - Program to find the first non repeated character in a string

Java - Program to find the first non repeated character in a string

Examples : Input - codeforeach , Output - d ; Input - principles , Output - r. Pseudo Algorithm : 1) Build a map consisting of each character of string with repetition count. i) Loop through the string characters ii) For each character,if the character key is found in the map...
increment the value by 1

Encoding vs Encryption vs Hashing

Encoding vs Encryption vs Hashing

We often see or hear the words such as encoding / encryption / hashing. These are related to techniques meant for data transformation from one format to another and used to enable data privacy or proper consumption of data by electronic devices such as computers. Lets have a quick look at the differences between these techniques...

Jsoup - Quick Start Example

Jsoup - Quick Start Example

Jsoup is a java library for parsing the html either from URL or String or File. Lets see an example of connecting to url and parsing the html ...

Java 8 - Lambda Expression example

Java 8 - Lambda Expression example

Lambda Expression Lambda expression is a new feature in Java 8 . Alternative to anonymous class implementation of interfaces ( with single abstract method ). syntax : (parameters) -> { body of statements } Example - Sorting the list of Employees using comparator Lets...
Java - Try vs Try-with-Resources

Java - Try vs Try-with-Resources

JDK 7 comes with try-with-resources feature which allows automatic closing of resources without explicit finally block leading to minimal code and avoids boilerplate code required for closing of resources...

www.000webhost.com