当前位置:网站首页>Filter the numbers and pick out even numbers from several numbers
Filter the numbers and pick out even numbers from several numbers
2022-07-05 06:17:00 【hamimelon2020】
<template>
<div>
<li v-for="n in evenNumbers" :key="n">{
{
n }}</li>
</div>
</template>
<script>
export default {
name: 'item',
data() {
return {
numbers: [ 1, 2, 3, 4, 5 ]
}
},
computed: {
evenNumbers() {
return this.numbers.filter(number => number % 2 === 0)
}
}
}
</script>
边栏推荐
- 1039 Course List for Student
- 2022年貴州省職業院校技能大賽中職組網絡安全賽項規程
- Leetcode-1200: minimum absolute difference
- Navicat連接Oracle數據庫報錯ORA-28547或ORA-03135
- NotImplementedError: Cannot convert a symbolic Tensor (yolo_boxes_0/meshgrid/Size_1:0) to a numpy ar
- C Primer Plus Chapter 15 (bit operation)
- How to understand the definition of sequence limit?
- LeetCode-54
- Règlement sur la sécurité des réseaux dans les écoles professionnelles secondaires du concours de compétences des écoles professionnelles de la province de Guizhou en 2022
- CPU内核和逻辑处理器的区别
猜你喜欢

MySQL advanced part 2: the use of indexes

redis发布订阅命令行实现

Error ora-28547 or ora-03135 when Navicat connects to Oracle Database

1.14 - assembly line

2021apmcm post game Summary - edge detection

Redis publish subscribe command line implementation

RGB LED infinite mirror controlled by Arduino

LVS简介【暂未完成(半成品)】

Is it impossible for lamda to wake up?

4. 对象映射 - Mapping.Mapster
随机推荐
多屏电脑截屏会把多屏连着截下来,而不是只截当前屏
Traversal of leetcode tree
可变电阻器概述——结构、工作和不同应用
LeetCode 1200. Minimum absolute difference
对for(var i = 0;i < 5;i++) {setTimeout(() => console.log(i),1000)}的深入分析
New title of module a of "PanYun Cup" secondary vocational network security skills competition
leetcode-3:无重复字符的最长子串
MySQL怎么运行的系列(八)14张图说明白MySQL事务原子性和undo日志原理
Quickly use Amazon memorydb and build your own redis memory database
Appium automation test foundation - Summary of appium test environment construction
Leetcode recursion
The difference between CPU core and logical processor
什么是套接字?Socket基本介绍
Leetcode-1200: minimum absolute difference
leetcode-556:下一个更大元素 III
Appium基础 — 使用Appium的第一个Demo
Leetcode-9: palindromes
1.15 - 输入输出系统
MySQL advanced part 1: index
Leetcode-31: next spread