Professional Documents
Culture Documents
a) int a[];
b) a[1] = a[-2] + 1;
c) int a(5);
d) int b[10];
b[10] = 5;
e) int b[10];
for ( i = 0; i <= 10; i++ )
{
b[i] = i;
}
2) Write a C program to read 6 floating point numbers into an array, and an integer in a variable; then
multiply each cell by the integer and store the result in the corresponding cell.
3) Write a C program that uses an array to input an integer and then outputs the number with the digits
reversed. For example the number 12345 will be printed as 5 4 3 2 1
4) Write a C program to read an integer from user, then search the array for that number
5) Write C++ program, to read X[ n ], and rotate the elements to the left by one position.