what difference between args.length and args.length() in
command line argument?



what difference between args.length and args.length() in command line argument?..

Answer / Rajeev Singh Gangwar

In JavaScript, `args.length` is used to get the number of command-line arguments passed directly to the script, while `args.length()` does not exist as a built-in method in JavaScript. Instead, you can use Array's length property or String's length property if args is an array containing strings.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More JavaScript Interview Questions

what is java?

2 Answers  


What are javascript objects?

1 Answers  


What is difference between local variable and global?

1 Answers  


What is a reverse string?

1 Answers  


Explain how to write class methods vs. Instance methods.

1 Answers  


program showing string concatenation?

4 Answers  


What are the difference between undefined and not defined in javascript?

1 Answers  


Define closure.

1 Answers  


Event handler Example

1 Answers  


List out all the falsifying tokens in Javascript?

1 Answers  


Explain the difference between java and javascript.

1 Answers  


What is the difference between the substr() and substring() functions in javascript?

1 Answers  


Categories