Answer to Question #268186 in C for Phn

Question #268186



2. Mr. Raju want to read 10 array elements and wants to display them in the reverse way. Write a C program to help Mr. Raju to display the array elements in the reverse way.






1
Expert's answer
2021-11-18T15:21:19-0500
#include<stdio.h>


int main(){
	printf("Enter the elements of the array:\n");
	int arr[10];
	int i=0;
	for(i=0; i<10; i++){
		scanf("%d", &arr[i]);
	}
	
	printf("The elements in reverse way is: \n");
	int j=0; 
	for(j=9; j>=0; j--){
		printf("%d  ", arr[j]);
	}
}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS