🚀 Hurry! Offer Ends In
00 Days
00 Hours
00 Mins
00 Secs
Enroll Now
X

MCQs on C Language

Ques 101

JOA-IT-2019

C भाषा में मोडुलो ऑपरेटर को _____ प्रतीक का उपयोग करके दर्शाया जाता है।

The modulo operator is represented using _____ symbol in C language.

[A] / (forward slash)

[B] ^ (caret)

[C] ! (exclamation)

[D] % (percentage)

Correct Answer : % (percentage)


Ques 102

JOA-IT-2019

निम्नलिखित में से कौन सा प्रतीक C भाषा में एड्रेस ऑपरेटर का प्रतिनिधित्व करता है?

Which of the following symbols represents the address operator in C language ?

[A] $ (dollar)

[B] * (asterisk)

[C] & (ampersand)

[D] ^ (caret)

Correct Answer : & (ampersand)


Ques 103

JOA-IT-2019

‘C’ में एक एस्केप अनुक्रम _____ वर्ण से शुरू होता है।

An escape sequence begins with a _____ character in ‘C’.

[A] $ (dollar)

[B] / (forward slash)

[C] % (percentage)

[D] \ (back slash)

Correct Answer : \ (back slash)


Ques 104

SSC Scientific Assistant CS_IT NOV -2017

एक 'सी' डेटा संरचना जिसे संरचना कहा जाता है, वस्तुओं का एक समूह है जिसमें प्रत्येक आइटम को उसके स्वयं के पहचानकर्ता द्वारा पहचाना जाता है, जिनमें से प्रत्येक को एक संरचना के रूप में जाना जाता है।

A ‘C’ data structure called a structure is a group of items in which each item is identified by its own identifier, each of which known as number of a structure members is also known as

[A] information

[B] field

[C] record

[D] data type

Correct Answer : field


Ques 105

SSC Scientific Assistant CS_IT NOV -2017

C फ़ंक्शन डिफ़ॉल्ट रूप से ________ मान लौटाता है।

C function return ________ value by default.

[A] character

[B] number

[C] integer

[D] float

Correct Answer : integer


Ques 106

SSC Scientific Assistant CS_IT NOV -2017

किसी फ़ंक्शन के तीव्र निष्पादन के लिए किस प्रकार का पैरामीटर पास किया जाता है?

Which type of parameter is passed in a function for faster execution?

[A] call by value

[B] Call by address

[C] Call by name

[D] Call by string

Correct Answer : call by value


Ques 107

SSC Scientific Assistant CS_IT NOV -2017

यदि p और q को क्रमशः 2 और 3 मान दिए गए हैं तो कथन p=q++;

If p and q are assigned the values 2 and 3 respectively then the statement p=q++;

[A] gives an error message

[B] assigns a values 4 to p

[C] assigns a value 3 to p

[D] assigns a value 2 to p

Correct Answer : assigns a value 3 to p


Ques 108

SSC Scientific Assistant IT - 2022

निम्नलिखित C भाषा कोड का आउटपुट क्या है?

What is the output of following C language code?

int main()
{
 int a=10,b,c; 
c=b=a;
c*=b*=a*a:
printf("a=%d b=%d c=%d",a,b,c); return 0;
}

[A] a=100 b=1000 c=10000

[B] a=10 b-1000 c=10000

[C] a=10 b=100c=1000

[D] a=0 b=10c=100

Correct Answer : a=10 b-1000 c=10000


Ques 109

SSC Scientific Assistant IT - 2022

निम्नलिखित C प्रोग्रामिंग भाषा कोड का आउटपुट क्या है?

What is the output of following C programming language code?

 void main() 
{
 int x=10; 
if(!!x) 
    printf("x=%d",x);}

[A] X=1

[B] X=0

[C] Error

[D] X=10

Correct Answer : X=10


Ques 110

SSC Scientific Assistant IT - 2022

निम्नलिखित C प्रोग्रामिंग भाषा कोड का आउटपुट क्या है?

What is the outout of following C Programming language code ?

int main() 
{ int a = 10 b = 4 c, d; 
c = a < 9;
d=a>3\&\& b! = 3 ;
printf("c=%d d=%d", c, d); 
return 0;
 }

[A] c=0 d=0

[B] c=1 d=0

[C] c=1 d=1

[D] c=0 d=1

Correct Answer : c=0 d=1


Ques 111

SSC Scientific Assistant IT - 2022

सी भाषा कोड में निम्नलिखित कथन में कौन सा ऑपरेटर अमान्य है?

Which operator is invalid in the following statement in the C language code?

a=4**5-8+5%7;

[A] +

[B] **

[C] -

[D] %

Correct Answer : **


Ques 112

SSC Scientific Assistant IT - 2022

निम्नलिखित C भाषा कोड का आउटपुट क्या है?

What is the output of the following C language code ?

int main() 
 x=4*4%5; 
printf("%d ",x); 
return 0; 
}

[A] 16

[B] 0.2

[C] 1

[D] 3

Correct Answer : 1


Ques 113

SSC Scientific Assistant IT - 2022

निम्नलिखित C भाषा कोड का आउटपुट क्या है?

What is the output of following C language code ?

int main(){
union { intx;
float y;
} printf("%ID",sizeof(a));}

[A] 2

[B] 3

[C] 4

[D] 5

Correct Answer : 4


Ques 114

SSC Scientific Assistant IT - 2022

निम्नलिखित C भाषा कोड की किस पंक्ति में त्रुटि है?

In which line of the following C language code has error?

int main()
{ int x=5;//line1
float y=2.25;//line2
printf("%d',x%y);//line 3
return 0; //line4
}

[A] Line 2

[B] Line 1

[C] Line 4

[D] Line 3

Correct Answer : Line 3


Ques 115

SSC Scientific Assistant IT - 2022

निम्नलिखित C भाषा कोड का आउटपुट क्या है?

What is the output of the following C language code ?

int main()
{
int a;
a=4%6%3;
printf("%d",a);
return 0;
}

[A] 2

[B] -1

[C] 0

[D] 1

Correct Answer : -1


Ques 116

TAC-2018

निम्नलिखित C प्रोग्राम के लिए क्या मुद्रित किया जाएगा?

What will be printed for the following C program ?

# include <sttdio.h>
Int main() {
      Int a = 100 , b=30;
      If(a<25)
           {a=a-50;}
Else{ b=b+50;}
Printf(“a=%d,b=%d”,a,b);
Return 0; 
}

[A] a=100,b=80

[B] a=100,b=30

[C] a=50, b=30

[D] a=50,b=80

Correct Answer : a=100,b=80


Ques 117

TAC-2018

निम्नलिखित C प्रोग्राम के लिए क्लोजिंग टैग अनिवार्य है

Closing tag is compulsory for the following C program

include <stdio.h>
 int main() { 
char myChar='A'; 
switch(myChar) { 
case 'A': printf("Chemistry, "); 
case 'B': case 'C': printf("Math, "); 
case 'D': case 'E': default : printf("Physics"); 
return 0; } 

[A] Chemistry ,

[B] Compiler error

[C] Chemistry , Math,

[D] Chemistry , Math ,Physics

Correct Answer : Chemistry , Math ,Physics


Ques 118

TAC-2018

निम्नलिखित C प्रोग्राम के लिए क्या मुद्रित किया जाएगा

What will be printed for the following C program

#include <stdio.h> 
int main() { 
char myChar[7]="Hanger", "ptr, 
ptr=myChar+4; 
*ptr='a'; 
printf("%s", myChar); 
return 0; }

[A] Hangear

[B] Hangr

[C] Hangar

[D] Hanger

Correct Answer : Hangar


Ques 119

TAC-2018

निम्नलिखित C फ़ंक्शन पर विचार करें, जब myFunction (5) को कॉल किया जाता है तो आउटपुट क्या होगा?

. Consider the following C function, What will be the output when myFunction (5) is called?

int myFunction(int x) 
{
 int sum=0; 
for (int i=1; i<=x; i++) 
{
 sum=sum+i;
 }
 printf("%d", sum) 
}

[A] 14

[B] 16

[C] 15

[D] 21

Correct Answer : 15


Ques 120

TAC-2018

निम्नलिखित C घोषणा पर विचार करें

Consider the following C declaration

#include <stdio.h>
 #include <string.h>
int main() { 
char data[10];
 char *myString="HAT"; 
int length=strlen(myString);
 printf("%d", length);
 return 0;
 }

[A] 2

[B] 4

[C] 3

[D] 5

Correct Answer : 3


Ques 121

Tech Assistant -2019

फ़ंक्शन घोषणा में निम्नलिखित में से कौन सा / से अनिवार्य है?

Which of the following is /are mandatory in function declaration ?

[A] Return type , function name only

[B] Return type ,Function name , parameter only

[C] Parameter , function name only

[D] Function name only

Correct Answer : Return type ,Function name , parameter only


Ques 122

Tech Assistant -2019

निम्नलिखित C कोड स्निपेट का आउटपुट क्या है?

What is the output of the following C code snippet ?

#include <stdio.h> 
void main(){
 char str1[]="ISRO", str2[]="ISRO";
 if (str1 str2) { printf("both are same"); 
}
else{ 
printf("both are NOT same"); 
}
 }

[A] Both are same

[B] Compiler error

[C] Both are not same

[D] None of the above

Correct Answer : Compiler error


Ques 123

Tech Assistant -2019

C में अप्रारंभीकृत पॉइंटर को क्या कहा जाता है

Uninitialized Pointer in C is called as

[A] Dangling pointer

[B] Null pointer

[C] Void pointer

[D] Wild pointer

Correct Answer : Wild pointer


Ques 124

Tech Assistant -2019

सी-प्रोग्राम का निम्नलिखित अंश क्या प्रिंट करता है? char c[]="LAKEVIEW"; char *p=c; printf("%s", p+p[3]-p[1]);

What does the following fragment of C-program print? char c[]="LAKEVIEW"; char *p=c; printf("%s", p+p[3]-p[1]);

[A] LAKEVIEW

[B] EVIEW

[C] VIEW

[D] IEW

Correct Answer : VIEW


Ques 125

Tech Assistant -2019

यदि निम्नलिखित फ़ंक्शन को sum(5) का उपयोग करके कॉल किया जाता है, तो printf कथन कितनी बार निष्पादित होगा:

If the following function is called using sum(5), how many times will the printf statement be executed:

intfunc(int n)
{
if(n==0)
 return 0;
printf("%d\n",n*n);
return (func(n-1) + n*n);

[A] 1 time

[B] 5 times

[C] 4 times

[D] None of the above

Correct Answer : 5 times


Ques 126

Tech Assistant -2019

यदि int प्रकार दो बाइट्स का है, तो नीचे दिए गए कोड का आउटपुट ज्ञात करें

If int type is of two bytes, find the output of the code given below

#include<stdio.h>
int main() 
{ 
int a[] = { 1, 2, 3, 4, 5} ; 
int*ptr; 
ptr = a; 
printf(" %d ", *( ptr + 1) ); 
return 0; 
}

[A] 5

[B] 3

[C] 2

[D] 4

Correct Answer : 2


Ques 127

Tech Assistant -2019

नीचे दिए गए कोड का आउटपुट ज्ञात करें

Find output of the code given below

#include<stdio.h>
int main() 
{ 
int a = 5; 
int*ptr ; 
ptr = &a; 
*ptr = *ptr * 3; 
printf("%d", a); 
return 0; 
}

[A] 15

[B] 13

[C] 14

[D] 12

Correct Answer : 15


Ques 128

Tech Assistant -2019

मान लें कि फ्लोट में 4 बाइट्स हैं, नीचे दिए गए कोड का आउटपुट ज्ञात करें:

Assume that float has 4 bytes, Find output of the code given below :

#include <stdio.h>
int main()
{
floatx[5] = {212.5, 210.0, 50.5, 1.5, 0.5};
float*ptr1 = &x[0];
float*ptr2 = ptr1 + 3;
printf("%f ", *ptr2);
printf("%d", ptr2 - ptr1);
return 0;
}

[A] 50.5 2

[B] 210.0 2

[C] 1.5 3

[D] 0.5 3

Correct Answer : 1.5 3


Ques 129

Tech Assistant -2019

नीचे दिए गए कोड का आउटपुट ज्ञात करें

Find output of the code given below

#include <stdio.h>
int main(void)
{
inti;
for(inti=0;i<3;i++)
 {
 switch(i)
 {
case 0: printf("a");
case 1: printf("b");
default: printf("c");break;
 }
 }
}

[A] abcbcc

[B] abc

[C] abccc

[D] abacbc

Correct Answer : abcbcc


Ques 130

Tech Assistant -2019

नीचे दिए गए कोड का आउटपुट ज्ञात करें

Find output of the code given below

#include<stdio.h>
void func(int* p, int*q) 
{ 
 p = q; 
 *p = 2; 
} 
int main() 
{ 
Int i = 0, j = 1; 
func(&i, &j); 
printf("%d,%d", i, j); 
return 0; 
}

[A] 0,1

[B] 0,2

[C] 2,0

[D] 2,1

Correct Answer : 0,2


Ques 131

Tech Assistant -2019

नीचे दिए गए कोड का आउटपुट ज्ञात करें

Find output of the code given below

#include <stdio.h>
intmain()
{
 Int arr[] = {1, 2, 3, 4, 5};
 int*p = arr;
 ++*p;
 p += 3;
 printf("%d", *p);
 return0;
}

[A] 1

[B] 2

[C] 34

[D] 4

Correct Answer : 4


Ques 132

Tech Assistant -2019

मान लें कि पूर्णांक डेटा प्रकार का आकार 4 बाइट्स है, नीचे दिए गए कोड का आउटपुट ज्ञात करें

Assume size of integer data type is 4 bytes,Find output of the code given below

#include <stdio.h>
void func(char**);
intmain()
{
 char*argv[] = { "sa", "ri", "ga", "ma", "pa", "da"};
 func(argv);
 return0;
}
voidfunc(char**p)
{
 char*t;
 t = (p += sizeof(int))[-1];
 printf("%s", t);
}

[A] sa

[B] ri

[C] ga

[D] ma

Correct Answer : sa


Ques 133

Tech Assistant -2019

सिलेंडर पर ब्लॉक के लिए I/O के अनुरोध के साथ एक डिस्क कतार पर विचार करें 98,183,37,122,14,124,65,67 डिस्क शेड्यूलिंग के लिए सबसे कम समय पहले एल्गोरिदम (SSTF) पर विचार करें। यदि प्रारंभिक हेड स्थिति 53 पर है, तो सिलेंडर में कुल हेड मूवमेंट है

Consider a disk queue with request for I/O to blocks on cylinders 98,183,37,122,14,124,65,67 Consider the shortest seek time first algorithm (SSTF) for disk scheduling.If the initial head position is at 53, the total head movement in cylinders is

[A] 640

[B] 236

[C] 208

[D] 288

Correct Answer : 288


Ques 134

Technical Assistant-2024

निम्नलिखित 'C' कोड स्निपेट का आउटपुट क्या है?

What is the output of the following 'C' code snippet?

#include<stdio.h>
tchange (int^ * b ,int^ * a) 
{ * a +=*a;
*b* =*a;
* a ++=++* b;
* - - b = * --a ;
 } 
void main() 
{
 int a = 2 b = 5; tchange(&a,&b); 
printf("%d %d",a,b); 
}

[A] 21 21

[B] 4

[C] 5

[D] 6

Correct Answer : 4


Ques 135

Technical Assistant-2024

निम्नलिखित सी प्रोग्राम स्निपेट में, प्रिंट होने वाला आउटपुट लिखें।

In the Following C program snippet , write the output that gets printed .

#include <stdio.h>
 main(){
 int x =2, y, z;
 x *= 3+ 2; 
x*= y = z = 4; 
printf("%d", x); 
}

[A] 10

[B] 40

[C] 20

[D] 2

Correct Answer : 40


Latest Updates