fun(int x)
{
if(x > 0)
fun(x/2);
printf("%d", x);
}
above function is called as:
fun(10);
what will it print?
}
Answer Posted / vinay
10,5,2,1
after that it terminated.
| Is This Answer Correct ? | 1 Yes | 4 No |
Post New Answer View All Answers
How can I ensure that integer arithmetic doesnt overflow?
What is typedef?
c language supports bitwise operations, why a) 'c' language is system oriented b) 'c' language is problem oriented c) 'c' language is middle level language d) all the above
Explain how can you determine the size of an allocated portion of memory?
Why does everyone say not to use scanf? What should I use instead?
Write program to remove duplicate in an array?
Write a program to maintain student’s record. Record should
not be available to any unauthorized user. There are three
(3) categories of users. Each user has its own type. It
depends upon user’s type that which kind of operations user
can perform. Their types and options are mentioned below:
1. Admin
(Search Record [by Reg. No or Name], View All Records,
Insert New Record, Modify Existing Record)
2. Super Admin
(Search Record [by Reg. No or Name], View All Records,
Insert New Record, Modify Existing Record, Delete Single Record)
3. Guest
(Search Record [by Reg. No or Name], View All Records)
When first time program runs, it asks to create accounts.
Each user type has only 1 account (which means that there
can be maximum 3 accounts). In account creation, following
options are required:
Login Name: <6-10 alphabets long, should be unique>
Password: <6-10 alphabets long, should not display
characters when user type>
Confirm Password:
How will you declare an array of three function pointers where each function receives two ints and returns a float?
What is the difference between array and pointer in c?
What is the difference between break and continue?
Do pointers need to be initialized?
If jack lies on Mon, Tue Wed and jill lies on Thursday, Friday and Saturday. If both together tell they lied yesterday. So c the given options and then c cos in the given dates one will be saying the truth and one will be lying. I got Thursday as option because jack is saying the truth he lied yest but jill is lying again as he lies on that day.
What is a substring in c?
5 Write an Algorithm to find the maximum and minimum items in a set of ‘n’ element.
why do some people write if(0 == x) instead of if(x == 0)?