当前位置:网站首页>JS arguments parameter usage and explanation
JS arguments parameter usage and explanation
2022-07-04 05:41:00 【Tianma 3798】
One 、arguments Parameter Introduction
arguments, It is js An object built into a function in , The values of the actual parameters of the execution function method are stored in arguments in ;
To get these arguments , It needs to be like an array , Use subscript / Index to locate each value , But it can't be said to be an array , Because it has other properties , Such as callee;
And you can't use it shift、push、join Other methods .
Named parameters that do not pass values are automatically assigned undefined;
arguments.length---- Number of parameters
arguments.callee()--- Adjust the Commission itself
Two 、 Use cases
Case study 1:
function show() {
console.info(arguments);
//arguments.callee()
}
show();
show(1, 2);
show(window, 1)
Case study 2:
function sum() {
var result = 0;
for (边栏推荐
- BeanFactoryPostProcessor 与 BeanPostProcessor 相关子类概述
- [Excel] 数据透视图
- input显示当前选择的图片
- How to clone objects
- Build an Internet of things infrared temperature measuring punch in machine with esp32 / rush to work after the Spring Festival? Baa, no matter how hard you work, you must take your temperature first
- SQL performance optimization skills
- js arguments参数使用和详解
- 拓扑排序和关键路径的图形化显示
- JS string splicing enhancement
- PostgreSQL has officially surpassed mysql. Is this guy too strong!
猜你喜欢

2022 t elevator repair operation certificate examination question bank and simulation examination

ansys命令
![BUU-Crypto-[GXYCTF2019]CheckIn](/img/b8/ad6c05977f6943f30e9975acb6eb6e.jpg)
BUU-Crypto-[GXYCTF2019]CheckIn

RSA加密应用常见缺陷的原理与实践

谷歌 Chrome 浏览器将支持选取文字翻译功能

VB. Net simple processing pictures, black and white (class library - 7)

js arguments参数使用和详解
![BUU-Crypto-[HDCTF2019]basic rsa](/img/d0/8e451dabb2a6897f6680220d16d04d.jpg)
BUU-Crypto-[HDCTF2019]basic rsa

(4) Canal multi instance use

Just do it with your hands 7 - * project construction details 2 - hook configuration
随机推荐
BUU-Crypto-Cipher
Viewing and using binary log of MySQL
ANSYS command
冲击继电器JC-7/11/DC110V
"In simple language programming competition (basic)" part 1 Introduction to language Chapter 3 branch structure programming
Zhanrui tankbang | jointly build, cooperate and win-win zhanrui core ecology
[paper summary] zero shot semantic segmentation
如何判断数组中是否含有某个元素
Void convolution, deformable convolution, deformable ROI pooling
C语言简易学生管理系统(含源码)
Just do it with your hands 7 - * project construction details 2 - hook configuration
Flink1.13 SQL basic syntax (I) DDL, DML
FreeRTOS 中 RISC-V-Qemu-virt_GCC 的 锁机制 分析
ansys命令
VB. Net calls ffmpeg to simply process video (class Library-6)
[excel] PivotChart
LC weekly 300
flink1.13 sql基础语法(一)DDL、DML
Simulink and Arduino serial port communication
ETCD数据库源码分析——初始化总览