View Single Post
Old 14-09-2007, 03:16 PM   #136 (permalink)
Gigacore
Dreamweaver
 
Gigacore's Avatar
 
Join Date: Aug 2006
Location: Bangalore
Posts: 3,904
Default Re: Post ur C/C++ Programs Here

Its ok buddy... now its working fine on 98 machine....


A Simple C Program to read and print a one-dimensional array

Code:
#include <stdio.h>
#include<conio.h>
void main()
{
	int a[10];
	int i,n;
	printf("\nEnter number of elements in the array:");
	scanf("%d",&n);
	printf("\nEnter the array elements\n");
	for(i=0;i<n;i++)
		scanf("%d",&a[i]);
	printf("\nArray elements are\n");
	for(i=0;i<n;i++)
		printf("\t%d",a[i]);
return 0;
Getch()
}
__________________
Today's noobs are tomorrow's geeks. Don't make fun of them.. encourage them. - Gigacore

Follow me on twitter.com/gigacore

Last edited by Gigacore; 30-10-2007 at 06:46 PM.
Gigacore is offline