0

i need someone to assist me in writting lamda expression.
THE CODE IS ABOUT 15 LINES
use this code snipt

List<fruit> fruits = createFruitArrayList () ; 
Frit LargeApple = null;
for (Fruit fruit:fruits) {
  if (fruit.getType() == null
     largeApple = fruit;
    }
  }

}

just rewrite plz

3
Contributors
4
Replies
16
Views
2 Years
Discussion Span
Last Post by jwenting
1

There are lots of people here who will freely give their time to help you become the best Java programmer you can be. There's nobody here who is interested in helping you cheat or doing your homework for you.

DaniWeb Member Rules (which you agreed to when you signed up) include:
"Do provide evidence of having done some work yourself if posting questions from school or work assignments"
http://www.daniweb.com/community/rules

1

That won't even compile.
And no, I won't rewrite that for you. I won't use lambdas, they're ugly, hard to read, an abomination.

0

I like lambdas, but I have no idea what your code is supposed to do, therefore have no idea how to refactor it. Do you really intend to repeatedly overwite the new values of largeApple?

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.