| Other C Interview Questions |
| |
| Question | Asked @ | Answers |
| |
| what is difference between array of characters and string | Accenture | 10 |
| I use turbo C which allocates 2 bytes for integers and 4
bytes for long. I tried to declare array of size 500000 of
long type using the following code...
long *arr;
arr=(long *)(malloc)(500000 * sizeof(long));
It gives a warning that "Conversion may lose significant
digits in function main"...
And the resulting array size was very less around 8400 as
compared to 500000. Any suggestions will be welcomed....
| | 2 |
| which header file contains main() function in c? | TCS | 3 |
| Can we include one C program into another C program if yes how? | Infosys | 4 |
| plssssss help !!....using array.. turbo c..
create a program that will accept number of words to be
consored.
.a word must not exceed 10 characters long
.the text to be entered will be no longer than 200 characters
.there will be no 10 words
example:
enter number of words to be censor: 5
enter words to censor:
windows
office
microsoft
bill
gates
enter text to censor:
bill gates founded microsoft and makes office and windows
sample output:
<consored> <censored> founded <censored> and makes
<censored> and <censored> | | 1 |
| What is the diffrent between while and do while statement ? | | 5 |
| Give a method to count the number of ones in a 32 bit number? | | 1 |
| wats the diference btwen constant pointer and pointer to a
constant.pls give examples. | | 6 |
| what is the function of .h in #include<stdio.h> in c ? | IBM | 9 |
| totally how much header files r in c language | TCS | 4 |
| AMMONG THE 4 STROAGE CLASSES IN C, WHICH ONE FASTEST? | HCL | 12 |
| what is compiler | | 5 |
| Write a program to interchange two variables without using
the third variable? | Accenture | 11 |
| how to exchnage bits in a byte
b7<-->b0 b6<-->b1 b5<-->b2 b4<-->b3
please mail me the code if any one know to
rajeshmb4u@gmail.com | Honeywell | 3 |
| Print all the palindrome numbers.If a number is not
palindrome make it one by attaching the reverse to it.
eg:123
output:123321 (or) 12321 | | 2 |
| What should not contain a header file? | | 2 |
| WAP to accept basic salary of an employee?
Calculate it HRA=25%,DA=30%,PF=30%&net salary display all
contents? | | 5 |
| 52.write a “Hello World” program in “c” without using a
semicolon?
53.Give a method to count the number of ones in a 32 bit number?
54.write a program that print itself even if the source file
is deleted?
55.Given an unsigned integer, find if the number is power of 2? | | 5 |
| write a program that finds the factorial of a number using
recursion? | | 1 |
| if a person is buying coconuts of Rs10,and then sell that
coconuts of Rs9,with the loss of one rupee.After that the
person became a millaniore.how? | Wipro | 5 |
| |
| For more C Interview Questions Click Here |