Saturday, June 29, 2019

One Dimensional Array Demonstration in C

In this article, I would like to show you how to declare and use one-dimensional array using C programming language. As a professional software engineer, one of the easiest data structure to be learned in a language is Arrays. They make so easy to solve common computer programming problems.

What the program will do is to list down all the values initialize in a variable using one-dimensional arrays. If you like my work please click the ads on my website to support my work. I will really appreciate your help. 

I am currently accepting programming work, IT projects, school and application development, programming projects, thesis and capstone projects, IT consulting work, computer tutorials, and web development work kindly contact me in the following email address for further details.  If you want to advertise on my website kindly contact me also in my email address also. Thank you.

My email address is the following jakerpomperada@gmail.com, jakerpomperada@aol.com, and jakerpomperada@yahoo.com.

My mobile number here in the Philippines is 09173084360.

My telephone number at home here in Bacolod City, Negros Occidental Philippines is  +63 (034) 4335675.

Here in Bacolod I also accepting computer repair, networking and Arduino Project development at a very affordable price.

My personal website is http://www.jakerpomperada.com


Program Listing


/*example_array.c
 Author   : Jake R. Pomperada,MAED-IT
 Tool     : Dev C++ Version 5.11
 Date     : November 29, 2018  Thursday 2:51 PM
*/
#include <stdio.h>
using namespace std;
int main()
{
int score[5] = {5,10,15,20,25};
int a=0;
printf("\n\n");
printf("\tOne Dimensional Array Demonstration");
printf("\n\n");
for(a=0; a<5; a++)
{
 printf("\t");
 printf("score[%d]  = %d\n ",a+1,score[a]);
}
 printf("\n\n");
 printf("\tEnd of Program");
 printf("\n\n");
}





No comments:

Post a Comment