Skip to content

Instantly share code, notes, and snippets.

@vmussak
Last active April 14, 2018 15:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vmussak/358c0fbfb198e2ea8a1b69da978b5674 to your computer and use it in GitHub Desktop.
Save vmussak/358c0fbfb198e2ea8a1b69da978b5674 to your computer and use it in GitHub Desktop.
var clientes = [
{ nome: 'Zé', sexo: 'Masculino', idade: 25 },
{ nome: 'Tonho', sexo: 'Masculino', idade: 18 },
{ nome: 'Maria', sexo: 'Feminino', idade: 25 }
];
var clientesMasculinosMaioresDe20Anos = clientes.where(x => x.sexo == 'Masculino' && idade > 20);
// [ { nome: 'Zé', sexo: 'Masculino', idade: 25 } ]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment