Mei Lycan

Generation

generate functionThu, 04 May 2023

crea una funcion que filtre de todos los objetos si son auto y son moto

const vehiculos = [ { tipo: 'auto', color: 'negro', marca: 'ford' }, { tipo: 'auto', color: 'negro', marca: 'ford' }, { tipo: 'moto', color: 'negro', marca: 'ford' }, { tipo: 'moto', color: 'negro', marca: 'ford' }, { tipo: 'moto', color: 'negro', marca: 'ford' }, { tipo: 'auto', color: 'negro', marca: 'ford' }, { tipo: 'auto', color: 'negro', marca: 'ford' }, { tipo: 'auto', color: 'negro', marca: 'ford' }, { tipo: 'moto', color: 'negro', marca: 'ford' }, { tipo: 'auto', color: 'negro', marca: 'ford' }, ]; const getAutos = vehiculos.filter(vehic

Javascript
Generate More

Want to kickstart your project?Use the new AI Studio to create your code