C Interview Questions
Questions Answers Views Company eMail

main() { int x=20,y=35; x = y++ + x++; y = ++y + ++x; printf("%d %d\n",x,y); } what is the output?

Ramco,

10 8146

main() { int x=5; printf("%d %d %d\n",x,x<<2,x>>2); } what is the output?

Ramco,

9 7764

#define swap1(a,b) a=a+b;b=a-b;a=a-b; main() { int x=5,y=10; swap1(x,y); printf("%d %d\n",x,y); swap2(x,y); printf("%d %d\n",x,y); } int swap2(int a,int b) { int temp; temp=a; b=a; a=temp; return; } what are the outputs?

Ramco,

4 10579




#include main() { char s1[]="Ramco"; char s2[]="Systems"; s1=s2; printf("%s",s1); } what will happen if you executed this code?

Ramco,

4 5570

#include main() { char *p1; char *p2; p1=(char *) malloc(25); p2=(char *) malloc(25); strcpy(p1,"Ramco"); strcpy(p2,"Systems"); strcat(p1,p2); printf("%s",p1); } Tell me the output?

Ramco,

6 7616

main() { int x=10,y=15; x=x++; y=++y; printf("%d %d\n",x,y); } output??

TCS, EBS, Ramco, Sangwin,

19 23081

main() { int a=0; if(a=0) printf("Ramco Systems\n"); printf("India\n"); } output?

Ramco,

7 6664

#include int SumElement(int *,int); void main(void) { int x[10]; int i=10; for(;i;) { i--; *(x+i)=i; } printf("%d",SumElement(x,10)); } int SumElement(int array[],int size) { int i=0; float sum=0; for(;i

Ramco,

5 5075




const char * char * const What is the differnce between the above tow?.

Ramco, TCS,

6 5905

two variables are added answer is stored on not for third variable how it is possible?

3 3355

how to convert binary to decimal and decimal to binary in C lanaguage

IBM, BPO, Far East Promotions, RBS,

7 21025

what is use#in c

3 3800

how to connect oracle in C/C++.

Wipro, TCS,

3 6607

How to use c/c++ code in JAVA

IBM, CDAC, Satyam, Scope International,

10 13361

Explain the importance and use of each component of this string: Foo.Bar, Version=2.0.205.0, Culture=neutral, PublicKeyToken=593777ae2d274679d

TCS,

1 4864


Post New C Questions






Un-Answered Questions { C }

How to check whether string is a palindrome, WITHOUT USING STRING FUNCTIONS?

12666


Using which language Test cases are added in .ptu file of RTRT unit testing???

1290


Write a C/C++ program to add a user to MySQL. The user should be permitted to only "INSERT" into the given database.

706


write a c program to calculate sum of digits till it reduces to a single digit using recursion

1851


What is the difference between if else and switchstatement

496






int far *near * p; means

2154


please explain clearly about execution of c program in detail,in which stage are the printf sacnf getting into exeecutable code

857


what is the difference between class and unio?

1066


In this problem you are to write a program that will cut some number of prime numbers from the list of prime numbers between 1 and N.Your program will read in a number N; determine the list of prime numbers between 1 and N; and print the C*2 prime numbers from the center of the list if there are an even number of prime numbers or (C*2)-1 prime numbers from the center of the list if there are an odd number of prime numbers in the list.

592


How to write a program for machine which is connected with server for that server automatically wants to catch the time for user of that machine?

838


Write a program to replace n bits from the position p of the bit representation of an inputted character x with the one's complement. Method invertBit takes 3 parameters x as input character, p as position and n as the number of positions from p. Replace n bits from pth position in 8 bit character x. Then return the characters by inverting the bits.

2816


how is the examination pattern?

832


please send me the code for multiplying sparse matrix using c

978


1234554321 1234 4321 123 321 12 21 1 1 12 21 123 321 1234 4321 1234554321

1915


write a program that types this pattern: 12345678987654321 12345678 87654321 1234567 7654321 123456 654321 12345 54321 1234 4321 123 321 12 21 1 1

1134