Skip to content
Related Articles

Related Articles

Improve Article

Josh Technology Interview Experience | MCQ Online questions

  • Difficulty Level : Easy
  • Last Updated : 04 Sep, 2019

Round 1:

1.What is the output of the following code?

Hey geek! It's time to become a success story instead of reading them. Check out our most renowned DSA Self Paced Course, now at a student-friendly price and become industry ready. And if you are looking for a more complete interview preparation resource, check out Complete Interview Preparation Course that will prepare you for the SDE role of your dreams!

Feeling prepared enough for your interview? Test your skills with our Test Series that will help you prepare for top companies like Amazon, Microsft, TCS, Wipro, Google and many more!

#include <stdio.h>



int main()
{
int x=5;
if(x==5){
if(x==5)break;
printf(“Hello”);
}
printf(“Hi”);
}

2.

What is the output of the following code?

#include <stdio.h>

int main()
{
int x=1, 2, 3;
printf(“%d”, i);
}

3.What is the output of the following code?

#include <stdio.h>

int main()
{
char s1[7]=”1234″, *p;
p=s1+3;
*p=’6′;
p=p-2;
*p=’8′;
printf(“%s”, s1);



}

4.What is the output of the following code?

#include <stdio.h>

int main()
{
int a=10, b=5, c=5;
int d;
d=b+c==a;
printf(“%d”, d);
}

5.What is the output of the following code?

#include <stdio.h>

int main()
{
char*p;
p=”hello”;
printf(“%c”, *&*p);
}

6. What is the output of the following code?

#include <stdio.h>

int main()
{
if(printf(“Hello”))
printf(“hi”);
else{
printf(“condition failed”);
}
}

7.What is the output of the following code?

#include <stdio.h>
#define int n= printf(“COMPANY”);
int main()
{
int n=10;
printf(“%d”, n);
}

8.What is the output of the following code?

#include <stdio.h>
int main()
{
int m, i=0, j=1, k=2;
m=i++||j++||k++;
printf(“%d %d %d %d”, m, i, j, k);
}

9.What is the output of the following code?

#include <stdio.h>
int main()
{
1|printf(“%d”, 10?0?5:1:12);
}

10.What is the output of the following code?

#include <stdio.h>
int main()
{
int i=0;
if(i==0){
i=(15, (i-3), 13, i++, i*10);
printf(i);
}
else
printf(“equal”);
}

 

My Personal Notes arrow_drop_up
Recommended Articles
Page :