answersLogoWhite

0


Best Answer

Arguments are fields that are given to a method when it is called, while parameters are the name for the received variables. For example:

public static void main(String[] args){

int arg1 = 0;

boolean arg2 = false;

String arg3 = "Some string";

function_a(arg1, arg2, arg3);

// These variables are called arguments because they are being passed

// to the function.

}

public static void function_a(int par1, boolean par2, String par3){

// These variables are called parameters because they are being received

// when the function is called.

}

I hope this helps.

User Avatar

Wiki User

12y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What is the simularities of parameter and arguments?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Engineering

Which MATH classs features does not use any parameter or arguments in Java?

The fields Math.PI and Math.E.


What parameter to a function is one for which an automatic value is supplied if do not explicitly use one in C programming?

You are referring to default arguments. However, C does not support default arguments. That's a C++ feature.


What is meant by arguments in c?

Arguments appear in functions and in function calls. Arguments passed to a function are known as actual arguments. The arguments used by the function are known as the formal arguments. In C, all arguments are passed by value, such that the formal argument is a copy of the actual argument.


Can there be at least some solution to determine the number of arguments passed to variable argument list function?

Yes. Use a control parameter before the variable argument list that determines how many arguments will follow. E.g., the printf() function uses a string parameter as the control parameter. The number of escape sequences in the string determines the number of arguments that are expected to follow, and each escape sequence in the string is expanded from left to right according to the arguments that follow. A simpler approach is to pass the number of arguments that will follow as a named argument. E.g.,void print_nums(int n, ...){// n tells you how many numbers are to be expected in the va_list.}AnswerYes, there can be solution.#1: explicitly specifing:extern void variadic_1 (int n, ...);variadic_1 (3, "first", "second", "third");#2: using terminator:extern void variadic_2 (...);variadic_2 ("first", "second", "third", NULL);


What is parameter constructor?

C++ permits us to achieve this objects bt passing argument to the constructor function when the object are created . The constructor that can take arguments are called parametrized constructors Example:- class abc { int m,n; public: abc(int x,int y); //paramererise constructor ................ ................. }; abc::abc(int x,int y) { m=x;n=y; }

Related questions

How do you pass the parameter in applet?

If you have the function main()... You can use its arguments to pass information.


Which MATH classs features does not use any parameter or arguments in Java?

The fields Math.PI and Math.E.


What parameter to a function is one for which an automatic value is supplied if do not explicitly use one in C programming?

You are referring to default arguments. However, C does not support default arguments. That's a C++ feature.


What is meant by arguments in c?

Arguments appear in functions and in function calls. Arguments passed to a function are known as actual arguments. The arguments used by the function are known as the formal arguments. In C, all arguments are passed by value, such that the formal argument is a copy of the actual argument.


What are arguments in C programming?

Arguments are used mostly in functions (or methods). Basically it can be any input parameter(s) which a function(s) can use to do it's work. For instance, sin(x) sinus is a function and x is it's argument.


Can there be at least some solution to determine the number of arguments passed to variable argument list function?

Yes. Use a control parameter before the variable argument list that determines how many arguments will follow. E.g., the printf() function uses a string parameter as the control parameter. The number of escape sequences in the string determines the number of arguments that are expected to follow, and each escape sequence in the string is expanded from left to right according to the arguments that follow. A simpler approach is to pass the number of arguments that will follow as a named argument. E.g.,void print_nums(int n, ...){// n tells you how many numbers are to be expected in the va_list.}AnswerYes, there can be solution.#1: explicitly specifing:extern void variadic_1 (int n, ...);variadic_1 (3, "first", "second", "third");#2: using terminator:extern void variadic_2 (...);variadic_2 ("first", "second", "third", NULL);


What is the simularities of mass and weight?

they have funiness


How do you spell simularities?

Similarities.


what is the simularities of winter and summer?

Hot


Is A query that prompts for input whenever it is run is a run-time query?

It is referred to as a parameter query.It is referred to as a parameter query.It is referred to as a parameter query.It is referred to as a parameter query.It is referred to as a parameter query.It is referred to as a parameter query.It is referred to as a parameter query.It is referred to as a parameter query.It is referred to as a parameter query.It is referred to as a parameter query.It is referred to as a parameter query.


What is parameter constructor?

C++ permits us to achieve this objects bt passing argument to the constructor function when the object are created . The constructor that can take arguments are called parametrized constructors Example:- class abc { int m,n; public: abc(int x,int y); //paramererise constructor ................ ................. }; abc::abc(int x,int y) { m=x;n=y; }


What is a parameter in Excel?

A parameter is a value that is used to carry out of task. It can be interpreted in a few ways. Parameters can be the values used to define filters if querying data in Excel. So if you have a list of data and want to show only some of it based on some criteria, that criteria can be referred to as parameters. If data is being read from an external source, it may require a parameter to define what data to show. Microsoft Access has something called a parameter query where a value is fed in at the time the query is run. That value is called a parameter. So if Excel is reading a parameter query from Access, it will need to provide a parameter to do it with. A parameter can be a value that is used in a function, though that is more commonly called an argument. In order for many functions to work they need values to work on. These are called arguments or occasionally parameters.