Determining the difference between odd and even numbers
Combining some of the existing answers, you can do

s.chars()                          // get the char stream
  .map(Character::getNumericValue) // convert to ints
  .map(n -&gt; n%2==0 ? -n : n)       // negate the even ones
  .sum()                           // sum it all up


This will give you the sum of the odds and the negative evens, which is the same as the sum of the odds minus the sum of the evens.

edit

In response to @kai, for absolute max readability, I'd probably do (pseudocode)

List&lt;int&gt; ints = s.chars().map(Character::getNumericValue)
Map&lt;Boolean, List&lt;int&gt;&gt; intsEven = ints.partitioningBy(n -&gt; n%2==0)
return intsEven.get(false).sum() - intsEven.get(true).sum()


or with isEven from the other answers and not defined here

List&lt;int&gt; ints = s.chars().map(Character::getNumericValue)
List&lt;int&gt; evens = ints.filter(isEven)
List&lt;int&gt; odds = ints.filter(not(isEven))
return odds.sum() - evens.sum()