摘要: 3、[简答题] 【静态方法引用】1. 定义一个函数式接口NumberToString,其中抽象方法String convert(int num),使用注解@FunctionalInterface2. 在测试类中定义static void decToHex(int num ,NumberToStrin 阅读全文
posted @ 2022-06-10 17:09 不只是智能hello 阅读(50) 评论(0) 推荐(0)
摘要: 2、[简答题] 【函数式接口】1. 定义一个函数式接口IntCalc,其中抽象方法int calc(int a , int b),使用注解@FunctionalInterface2. 在测试类中定义static void getProduct(int a , int b ,IntCalc calc) 阅读全文
posted @ 2022-06-10 17:00 不只是智能hello 阅读(104) 评论(0) 推荐(0)
摘要: 1、[简答题] 【函数式接口】1. 定义一个函数式接口CurrentTimePrinter,其中抽象方法void printCurrentTime(),使用注解@FunctionalInterface2. 在测试类中定义static void showLongTime(CurrentTimePrin 阅读全文
posted @ 2022-06-10 16:43 不只是智能hello 阅读(41) 评论(0) 推荐(0)