1,758 views
2 votes
2 votes

What will be the output of following programs :

void fun1(struct node* head)

 {

    for(head == NULL)
    {
        return;
    }

    fun1(head->next);

    printf("%d  ", head->data);
 }

 And this one !

 

void fun1(struct node* head)

 {

    while(head == NULL)
    {
        return;
    }

    fun1(head->next);

    printf("%d  ", head->data);
 }



 

Please log in or register to answer this question.

Related questions

0 votes
0 votes
1 answer
1
1 votes
1 votes
1 answer
2
. asked Apr 2, 2017
1,529 views
What will be the output of the following C program? If you think it will give a runtime error, you need to mention it. In either case,your answer must include proper just...
0 votes
0 votes
2 answers
3
Nitesh Choudhary asked Apr 21, 2017
1,323 views
#include<stdio.h>int main(){ int i=10; printf("address of i=%d value of i=%d",&i,i); &i=7200; printf("address of i=%d value of i=%d",&i,i); return 0;...