Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

import java.util.function.DoubleToIntFunction;

public class Main {

    public static void main(String[] args) {
        DoubleToIntFunction df = (x) -> {
            return (int) x + 2;
        };

        System.out.println(df.applyAsInt(3.14));
    }
}