가장 많이 묻는 면접 질문과 답변 & 온라인 테스트
면접 준비, 온라인 테스트, 튜토리얼, 라이브 연습을 위한 학습 플랫폼

집중 학습 경로, 모의고사, 면접 준비 콘텐츠로 실력을 키우세요.

WithoutBook은 주제별 면접 질문, 온라인 연습 테스트, 튜토리얼, 비교 가이드를 하나의 반응형 학습 공간으로 제공합니다.

Prepare Interview

모의 시험

홈페이지로 설정

이 페이지 북마크

이메일 주소 구독
/ 면접 주제 / Java 8
WithoutBook LIVE Mock Interviews Java 8 Related interview subjects: 39

Interview Questions and Answers

Know the top Java 8 interview questions and answers for freshers and experienced candidates to prepare for job interviews.

Total 30 questions Interview Questions and Answers

The Best LIVE Mock Interview - You should go through before interview

Know the top Java 8 interview questions and answers for freshers and experienced candidates to prepare for job interviews.

Interview Questions and Answers

Search a question to view the answer.

Intermediate / 1 to 5 years experienced level questions & answers

Ques 1

What is lambda expression?

Lambda expression is anonymous function which have set of parameters and a lambda (->) and a function body. You can call it function without name.

Structure of Lambda Expressions:
(Argument List) ->{expression;} or
(Argument List) ->{statements;}

For instance, the Runnable interface is a functional interface, so instead of:
Thread thread = new Thread(new Runnable() {
    public void run() {
        System.out.println("Hello World!");
    }
});
 
Using Lambda you can simply do the following:
Thread thread = new Thread(() -> System.out.println("Hello World!"));

Functional interfaces are usually annotated with the @FunctionalInterface annotation - which is informative and does not affect the semantics.
복습용 저장

복습용 저장

이 항목을 북마크하거나, 어렵게 표시하거나, 복습 세트에 넣을 수 있습니다.

내 학습 라이브러리 열기
도움이 되었나요?
Add Comment View Comments
Ques 2

Given a list of employees, sort all the employee on the basis of age by using java 8 APIs only.

You can simply use sort method of list to sort the list of employees.
List<Employee> employeeList = createEmployeeList();
        employeeList.sort((e1,e2)->e1.getAge()-e2.getAge());
        employeeList.forEach(System.out::println);
복습용 저장

복습용 저장

이 항목을 북마크하거나, 어렵게 표시하거나, 복습 세트에 넣을 수 있습니다.

내 학습 라이브러리 열기
도움이 되었나요?
Add Comment View Comments
Ques 3

Given the list of employees, find the employee with name 'John' using Java 8 API.

Check the following code:
List<Employee> employeeList = createEmployeeList();
        Optional<Employee> e1 = employeeList.stream()
                  .filter(e->e.getName().equalsIgnoreCase("Mary")).findAny();
        if(e1.isPresent())
            System.out.println(e1.get());
복습용 저장

복습용 저장

이 항목을 북마크하거나, 어렵게 표시하거나, 복습 세트에 넣을 수 있습니다.

내 학습 라이브러리 열기
도움이 되었나요?
Add Comment View Comments
Ques 4

Given a list of employee, find maximum age of employee using Java 8 API.

Check the following code:
List<Employee> employeeList = createEmployeeList();
        OptionalInt max = employeeList.stream().
                          mapToInt(Employee::getAge).max();
        if(max.isPresent())
            System.out.println("Maximum age of Employee: "+max.getAsInt());
복습용 저장

복습용 저장

이 항목을 북마크하거나, 어렵게 표시하거나, 복습 세트에 넣을 수 있습니다.

내 학습 라이브러리 열기
도움이 되었나요?
Add Comment View Comments
Ques 5

Provide some examples of Intermediate operations.

Example of Intermediate operations are:
  • filter(Predicate)
  • map(Function)
  • flatmap(Function)
  • sorted(Comparator)
  • distinct()
  • limit(long n)
  • skip(long n)
복습용 저장

복습용 저장

이 항목을 북마크하거나, 어렵게 표시하거나, 복습 세트에 넣을 수 있습니다.

내 학습 라이브러리 열기
도움이 되었나요?
Add Comment View Comments

Most helpful rated by users:

Copyright © 2026, WithoutBook.