Skip to main content

Type of user defined function.

1.)No argument and no return
2.)With argument and no return
3.)No argument and with return
4.)With argument and with return
             
1.)No argument and no return
In this type of function,there is no argument and function doesn't return any value.So,the datatype of the function must be "void"
syntax:-
void function name()
{
statement;
..........
........
}
for example:-
write a program to input two number by the keyboards and calculate sum using function no argument and no return.
void sum()
{
int s,a,b;
printf("\n enter two numbers");
scanf("%d%d",&a,&b);
s=a+b;
printf("\n sum=%d",s);
}
void main()
{
sum();
getch();
}

Comments

Post a Comment

Popular posts from this blog

What is sequential flow chart?

These types of flow chart indicates that the flow of control normally passes from one instructions to the next in a sequence with in a programme. Example :- design a flow chart to calculate addition of two number                          

React Js interview questions

 

เคชुเคธ्เคคเค•ों เค•ी เคฎเคนเคค्เคต เคนिंเคฆी เคฎें | Importance of book

เคชुเคธ्เคคเค•ों เค•ी เคฎเคนเคค्เคต เค•िเคคाเคฌों เค•े เคชाเคธ เค†เคชเค•े เคœीเคตเคจ เค•े เคฌเคนुเคค เคธाเคฐे เคธเคตाเคฒ เค•े เคœเคตाเคฌ เคนोเคคे เคนैं | เคฏเคน เค†เคชเค•े เคธเคฌเคธे เค…เคš्เค›े เคฆोเคธ्เคค เคนोเคคे เคนैं เคชुเคธ्เคคเค•ें เค‡ंเคธाเคจ เค•ी เคธเคฌเคธे เค…เคš्เค›ी เค”เคฐ เคญเคฐोเคธेเคฎंเคฆ เคฆोเคธ्เคค เคนोเคคी เคนैं | เคฏเคน เคตเคน เคฆोเคธ्เคค เคนोเคคी เคนै เคœो เค†เคชเค•ो เค•เคญी เคงोเค–ा เคจเคนीं เคฆेเคคी | เคฏเคน เคฎुเคถ्เค•िเคฒ เคธเคฎเคฏ เคฎें เค†เคชเค•ी เคนเคฎेเคถा เคนौเคธเคฒा เคฌเคข़ाเคคी เคนैं , เค†เคชเค•े เคšेเคนเคฐे เคชเคฐ เคฎुเคธ्เค•ुเคฐाเคนเคŸ เคญी เคฒाเคคी เคนैं , เค†เคชเค•ी เค†ंเค–ों เคฎें เค†ंเคธू เคญी เคฒाเคคी เคนैं , เค”เคฐ เคฆुเคจिเคฏा เคญเคฐ เค•ी เคธเคนी เค”เคฐ เคธเคš्เคšी เคœाเคจเค•ाเคฐिเคฏां เคฆेเคคी เคนै | 23 เค…เคช्เคฐैเคฒ เค•ो เคตเคฐ्เคฒ्เคก เคฌुเค• เคกे เค•े เคฐूเคช เคฎें เคฎเคจाเคฏा เคœाเคคा เคนै| เค…เคชเคจे เคง्เคฏाเคจ เคฆिเคฏा เคนोเค—ा เค•िเคคाเคฌे เคธे เคเค• เค…เคฒเค— เคคเคฐเคน เค•ी เค–ुเคถเคฌू เค†เคคी เคนैं เค”เคฐ เค‡เคธ เค–ुเคถเคฌू เค•ो เค‡ंเค—्เคฒिเคถ เคฎें BIBLIOSMIA เค•เคนเคคे เคนैं | เค‡ंเคŸเคฐเคจेเคŸ เค•े เคฎुเค•ाเคฌเคฒे เค•िเคคाเคฌों เคฎें เคชเคข़ी เค—เคˆ เคฌाเคคें เคฒंเคฌे เคธเคฎเคฏ เคคเค• เคฏाเคฆ เคฐเคนเคคी เคนैं | เค•िเคคाเคฌों เคธे เคœुเคก़ी เคคीเคจ เคฎเคนเคค्เคตเคชूเคฐ्เคฃ เคฌाเคคें 1.) เค•िเคคाเคฌें เคนเคฎें เค•เคฒ्เคชเคจा เค•ी เคฆुเคจिเคฏा เคฎें เคฒे เคœाเคคी เคนैं | เคนเคฎाเคฐी เค•เคฒ्เคชเคจा เค•ी เคฆुเคจिเคฏा เค•ो เคธुंเคฆเคฐ เค”เคฐ เคฎเคœเคฌूเคค เคฌเคจाเคคी เคนै | เคตเคน เคนเคฎाเคฐे เคชैเคฐ เคœเคฎीเคจ เคชเคฐ เคนोเคจे เคฆेเคคी เคนैं เค”เคฐ เค…เค—เคฐ เคง्เคฏाเคจ เคธे เคชเคข़ेंเค—े เคคो เคเคธा เคฒ...