Java Introduction to Functional Programming Java's Functional Toolset Using forEach

Trevor Braxton-Barto
PRO
Trevor Braxton-Barto
Pro Student 1,258 Points

Error in Dr.Java

File: C:\Users\Trevor\Desktop\School\TeamTreehouse\Functional Java\lcc-java-fp-printer-1.0.3\src\main\java\com\teamtreehouse\challenges\Printer.java [line: 23] Error: Lambda expressions are allowed only at source level 1.8 or above

I have the most updated version of Java, and my compiler, Dr.Java, states that they support Java 6, 7, and 8. The challenge is simple, and I've been using Lambda expressions/operations for a while on a challenge question site which uses an online compiler, so I'm sure there isn't anything wrong with my code.

1 Answer

Craig Dennis
STAFF
Craig Dennis
Treehouse Teacher

I found this: http://www.drjava.org/docs/user/ch06s03.html

This error is suggesting that you need to set your compiler to Java 8 (or 1.8). I do recommend you use IntelliJ, but this should work.

Trevor Braxton-Barto
Trevor Braxton-Barto
Pro Student 1,258 Points

Thanks Craig!

Actually miles ahead here: watching you use IntelliJ in such a swift and succinct way persuaded me to get it yesterday!