program to find a smallest number in an array
Answer Posted / .::get lost::.
#include<stdio.h>
#include<conio.h>
void main()
{
int a[20],n,i,s;
scanf("%d",&n);
for(i=0;i<n;i++)
{
scanf("%d",&a[i]);
}
s=a[0];
for(i=0;i<n;i++)
{
if(s>a[i])
{
s=a[i];
}
}
printf("the smallest number is %d",s);
getch();
}
| Is This Answer Correct ? | 24 Yes | 10 No |
Post New Answer View All Answers
the process of defining something in terms of itself is called (or) in C it is possible for the functions to call themselves. A function called a) nested function b) void function c) recursive function d) indifinite function
How to write a code for implementing my own printf() and
scanf().... Please hep me in this... I need a guidance...
Can you give an coding for c... Please also explain about
the header files used other than #include
Is malloc memset faster than calloc?
Why is %d used in c?
What is a program?
What are directives in c?
What is the explanation for the dangling pointer in c?
What is difference between constant pointer and constant variable?
Why dont c comments nest?
What is extern storage class in c?
disply the following menu 1.Disply 2.Copy 3.Append; as per the menu do the file operations 4.Exit
my project name is adulteration of chille powder.how can i explain it to the hr when he asks me about the project?
What is LINKED LIST? How can you access the last element in a linked list?
Why main function is special give two reasons?
What is the -> in c?