Saturday 7 October 2023

1. Given a list of integers, find out all the even numbers that exist in the list using Stream functions? By Java 8

 


Description:
Given a list of integers, find out all the even numbers that exist in the list using Stream functions?

Code:
?
1
2
3
4
5
import java.util.*; import java.util.stream.*; public class EvenNumber { public static void main(String args[]) { List<Integer> list = Arrays.asList(10, 15, 8, 49, 25, 98, 32); list.stream().filter(n -> n % 2 == 0).forEach(System.out::println); }

Output: 10, 8, 98, 32

Friday 5 May 2023

Java Interview Programs And solutions List for experiences in 2023.

Latest java interview Questions and Solution.


In this section, we are giving few java interview programs faced by some of my friends. If you come across any questions, post it to me. I can provide solutions.

  1. List of All Interviw Program.
    1. How to find Reverse Sting in java.
  2. 2. Count occurrences of character in string java using hashmap.
  3. 3.How to print all map values in java.
  4. 4.How to remove duplicate Characters from a String in java.
  5. 5.How to find armstrong number in java.
  6. 6.Write a Program to find ASCII values in java.
  7. 7. How to check Even OR Odd using scanner in java.
  8. 8.Factorial program in java.
  9. 9.Program to print Fibonacci Series using for loop in java.
  10. 10. FizzBuzz Program in Java - Interview Question
  11. 11. Palindrome program in java.
  12. 12. Swapping of two Numbers in java without third variable.
  13. 13. Example of Java Serialization.
  14. 14.Example of Java Deserialization .

Spring Notes

Spring Boot Interview Question Answer

Interview Programe