answersLogoWhite

0


Best Answer

int comp(const int a1[], const int a2[], const int size) {

int i;

for(i = 0; i < size; ++i) {

if(a1[i] != a2[i]) {

return 0;

}

}

return 1;

}

User Avatar

Wiki User

15y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: 1 write a c function that takes a parameters two integer arrays and their sizeboth arrays are of the same size and returns a 1true if the arrays have the same contents or a 0 false if not?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

How do declare function pointer having two integer parameters and returning integer pointers?

// declare a function int* function(int, int); or int* (function)(int, int); // declare a pointer to a function int* (*pointer_to_function)(int, int);


Write a function prototype named test that accepts two parameters an integer and character and returns a float?

float test(int, char);


Is the greatest integer function a continuous funcion?

No. It has a discontinuity at every integer value.


How do you print size of integer?

the size of an integer is determaind by using the function "sizeof(c)",here 'c' is any integer.


What is the greatest integer function of -50.95?

-51


What is function calling in c plus plus?

Function calling is where your code branches off to execute a function and then returns to the instruction following the call. The function may also return a value that can be stored and/or processed by the code that called it. Functions allow common code to be separated from the code that uses the common code, thus reducing maintenance (the code in the function is written once, rather than every time it is required).


Why you use 'integer' before function in C language?

To specify the return-type of the function.


What is a function used to convert ASCII to integer?

atoi


The greatest integer function and absolute value function are both examples of functions that can be defined as what?

Both the Greatest Integer Function and the Absolute Value Function are considered Piece-Wise Defined Functions. This implies that the function was put together using parts from other functions.


How to Write a C function which accepts two integer parameters a and b and returns the larger of the two?

This smells like homework, so I'll only give you pseudo-code: decimal returnLargest(decimal a, decimal b) is a &gt; b ? then, return a, else, return b;


What is the INT functions?

The INT function is to convert something into an integer. An integer is a number that goes out two decimal places.


What is bracket function?

x = the largest integer not exceeding x