Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

program to find a smallest number in an array

Answer Posted / asif ali afsar

#include<stdio.h>
#include<conio.h>
void main()
{
int a[10],b,c,n;
clrscr();
printf("How many size you want to Cheah\n");
scanf("%d",&n);
printf("Enter the numbers\n");
for(b=0; b<n; b++)
{
scanf("%d",&a[b]);
}
for(b=0; b<n; b++)
{
if(c<a[b])
{
c=c;
}
else
{
c=a[b];
}
}
printf("smalest no is %d",c);
getch();
}

Is This Answer Correct ?    3 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are qualifiers and modifiers c?

1003


How can I read a binary data file properly?

1160


What is the c value paradox and how is it explained?

1052


What are identifiers and keywords in c?

1093


What does *p++ do? What does it point to?

1059


What are file streams?

1010


What is #include stdio h and #include conio h?

1101


how to execute a program using if else condition and the output should enter number and the number is odd only...

2292


What are the different file extensions involved when programming in C?

1251


What is the difference between struct and typedef struct in c?

1123


What are the uses of a pointer?

1151


what do u mean by Direct access files? then can u explain about Direct Access Files?

2087


What is a null string in c?

1035


What are the ways to a null pointer can use in c programming language?

1137


What is wrong in this statement? scanf(ā€œ%dā€,whatnumber);

1234