Skip to content

Instantly share code, notes, and snippets.

@NZhuravlev
Created May 19, 2016 13:17
Show Gist options
  • Save NZhuravlev/4d03843859795d6d759086c1b8489a2a to your computer and use it in GitHub Desktop.
Save NZhuravlev/4d03843859795d6d759086c1b8489a2a to your computer and use it in GitHub Desktop.
package com.doublescoring.socredit
class Customer {
List<Order> orders;
}
class Order {
List<String> products;
}
println([new Customer(orders: [new Order(products: ["гавно", "шлак"])])]
.collectMany { it.orders }
.collectMany { it.products }
.findAll { it != "гавно" }
.size()
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment