SlideShare a Scribd company logo
1 of 4
Download to read offline
KNOW YOUR CODING SKILLS

DEMO TEST
Name : ………………………………….. Class: ………….. Date : ………………..
Total Questions: 20

Max. Time : 30 Minutes

Note: 1 Mark for right answer and -0.25 mark for Wrong Answer.

Q.1 Which of the following special symbol allowed in a variable name?
A.

* (asterisk)

B.

| (pipeline)

C.

- (hyphen)

D.

_ (underscore)

Q.2 Point Out The error in the following program.
#include<stdio.h>
int main()
{
display();
return 0;
}
void display()
{
printf("Know Your Coding Skills");
}
A. No error

B. display() doesn't get invoked.

C. display() is called before it is defined

D. None of these

Q.3 What is the name of the man who is invented to c?
A. Charles Babbage
C. Dennis & Ritchie

B. Dennis Ritchie
D. None

Q.4 what will be the output?
main()
{ int n=125,sum=0,res ;
while(n>0)
{
res=n%10; sum +=res; n/=10;
}
printf("Sum is %d",sum);
}
a) error

b)8

Q.5 What will be the output?
main()
{

c)7

d) none
KNOW YOUR CODING SKILLS
int a=9;
if(a=5){
printf("Bye");
}
printf("Welcome");}
A. error
C. welcome

B. compile failed
D. Bye

Q.6 Which one is the correct order of evaluation for the below expression?
z=x+y*z/4%2-1
A. * / % + - =
C. / * % - + =

B. = * / % + D. * % / - + =

Q.7 What will be the output of printf("n");
A. n

B.  n

C. error

D. none

Q.8 In C , the execution of the program starts from ?
A. the firstly defined function

B. main( ) function

C . the lastly defined function

D. none of these

Q.9 How many time the following function be called
main( )
{
int j;
j=10;
fun(j);
}
fun(int j)
{
if( j !=5)
fun( j-1 );
}

A.10 times

B.5 times

C.6 times

D.Infinite loop

Q.10. C++ was invented by
A. Donald Drum
C. Bjarne Stroustrup

B. Ken Thompson
D. Dennis Ritchie
KNOW YOUR CODING SKILLS

Q.11. Find out the error in following block of code.
If (x = 100)
Cout << “x is 100”;
A. 100 should be enclosed in quotations
B. There is no semicolon at the end of first line
C. Equals to operator mistake
D. Variable x should not be inside quotation

Q12. C provides loop constructs for performing loop operations. They are

A. The WHILE statement
C. The FOR statement

B. The DO statement
E. None of above

D. All of above

Q.13.What will this program display?
#include <stdio.h>
main()
{
float f;
f=10/3;
printf ("%d",f);
}

A. 3.3

B. 3.0

C. 3

D. 0

Q.14. The traditional way to create an infinite loop in C is

A. FOR ( ; ; )…
D. All of above

B. IF (=) BREAK;

C. WHILE ()…
E None of above

Q.15 The comma operator (,) is primarily used in conjunction with

A.FOR statement
D. All of above

B.IF-ELSE statement

C.DO-While statement
E. None of above

Q.16. Overloaded functions are
A.

Very long functions that can hardly run

B..

One function containing another one or more functions inside it.

KNOW YOUR CODING SKILLS

C.
Two or more functions with the same name but different number of parameters or
type.
D.

None of above

Q.17 What is the output of code given below?
#include<stdio.h>
main()
{
const int i =4;
float j;
j = ++i;
printf(“ %d",i++);
}
A.5

B. 6

C. 4

D. Compiler error

Q.18 Which of the following can not be used as Identifier ?
A.Letters

B.Digits

Q.19 In an assignment statement

C.Underscores

D Spaces

a=b; Which of the following statement is true?

A. The variable a and the variable b are equal.
B. The value of b is assigned to variable a but the later changes on variable b will not
effect the value of variable a
C. The value of b is assigned to variable a and the later changes on variable b will effect
the value of variable a
D. The value of variable a is assigned to variable b and the value of variable b is assigned
to variable a.

Q.20 Evaluate ! (1&&!(0||1)).

A. True

B. False

C. Unevaluatable

D. 0

More Related Content

More from manish katara

More from manish katara (20)

Some important tips for control systems
Some important tips for control systemsSome important tips for control systems
Some important tips for control systems
 
Electronics ckts symbols
Electronics ckts symbolsElectronics ckts symbols
Electronics ckts symbols
 
Ece interview questions with answers
Ece interview questions with answersEce interview questions with answers
Ece interview questions with answers
 
ppt on embedded system
ppt on embedded systemppt on embedded system
ppt on embedded system
 
all india radio
 all india radio all india radio
all india radio
 
embedded system report
embedded system reportembedded system report
embedded system report
 
1 6
1 61 6
1 6
 
Ch05
Ch05Ch05
Ch05
 
Syllabuswise analyse of gate
Syllabuswise analyse of gate Syllabuswise analyse of gate
Syllabuswise analyse of gate
 
Os
OsOs
Os
 
Gate ece question paper with answers 2011
Gate ece question paper with answers 2011Gate ece question paper with answers 2011
Gate ece question paper with answers 2011
 
Gate 2013 complete solutions of ec electronics and communication engineering
Gate 2013 complete solutions of ec  electronics and communication engineeringGate 2013 complete solutions of ec  electronics and communication engineering
Gate 2013 complete solutions of ec electronics and communication engineering
 
Pcm
PcmPcm
Pcm
 
Final ppt w o optical fiber
Final ppt w o optical fiberFinal ppt w o optical fiber
Final ppt w o optical fiber
 
3 broadband servies-250611
3 broadband servies-2506113 broadband servies-250611
3 broadband servies-250611
 
Final ppt
Final pptFinal ppt
Final ppt
 
Fina lindustrial tour report
Fina lindustrial tour reportFina lindustrial tour report
Fina lindustrial tour report
 
Gsm overview
Gsm overviewGsm overview
Gsm overview
 
New final bsnl training report
New final bsnl training report New final bsnl training report
New final bsnl training report
 
Gate college
Gate collegeGate college
Gate college
 

Recently uploaded

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 

Recently uploaded (20)

Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 

Test for computer languages

  • 1. KNOW YOUR CODING SKILLS DEMO TEST Name : ………………………………….. Class: ………….. Date : ……………….. Total Questions: 20 Max. Time : 30 Minutes Note: 1 Mark for right answer and -0.25 mark for Wrong Answer. Q.1 Which of the following special symbol allowed in a variable name? A. * (asterisk) B. | (pipeline) C. - (hyphen) D. _ (underscore) Q.2 Point Out The error in the following program. #include<stdio.h> int main() { display(); return 0; } void display() { printf("Know Your Coding Skills"); } A. No error B. display() doesn't get invoked. C. display() is called before it is defined D. None of these Q.3 What is the name of the man who is invented to c? A. Charles Babbage C. Dennis & Ritchie B. Dennis Ritchie D. None Q.4 what will be the output? main() { int n=125,sum=0,res ; while(n>0) { res=n%10; sum +=res; n/=10; } printf("Sum is %d",sum); } a) error b)8 Q.5 What will be the output? main() { c)7 d) none KNOW YOUR CODING SKILLS
  • 2. int a=9; if(a=5){ printf("Bye"); } printf("Welcome");} A. error C. welcome B. compile failed D. Bye Q.6 Which one is the correct order of evaluation for the below expression? z=x+y*z/4%2-1 A. * / % + - = C. / * % - + = B. = * / % + D. * % / - + = Q.7 What will be the output of printf("n"); A. n B. n C. error D. none Q.8 In C , the execution of the program starts from ? A. the firstly defined function B. main( ) function C . the lastly defined function D. none of these Q.9 How many time the following function be called main( ) { int j; j=10; fun(j); } fun(int j) { if( j !=5) fun( j-1 ); } A.10 times B.5 times C.6 times D.Infinite loop Q.10. C++ was invented by A. Donald Drum C. Bjarne Stroustrup B. Ken Thompson D. Dennis Ritchie KNOW YOUR CODING SKILLS Q.11. Find out the error in following block of code.
  • 3. If (x = 100) Cout << “x is 100”; A. 100 should be enclosed in quotations B. There is no semicolon at the end of first line C. Equals to operator mistake D. Variable x should not be inside quotation Q12. C provides loop constructs for performing loop operations. They are A. The WHILE statement C. The FOR statement B. The DO statement E. None of above D. All of above Q.13.What will this program display? #include <stdio.h> main() { float f; f=10/3; printf ("%d",f); } A. 3.3 B. 3.0 C. 3 D. 0 Q.14. The traditional way to create an infinite loop in C is A. FOR ( ; ; )… D. All of above B. IF (=) BREAK; C. WHILE ()… E None of above Q.15 The comma operator (,) is primarily used in conjunction with A.FOR statement D. All of above B.IF-ELSE statement C.DO-While statement E. None of above Q.16. Overloaded functions are A. Very long functions that can hardly run B.. One function containing another one or more functions inside it. KNOW YOUR CODING SKILLS C. Two or more functions with the same name but different number of parameters or type.
  • 4. D. None of above Q.17 What is the output of code given below? #include<stdio.h> main() { const int i =4; float j; j = ++i; printf(“ %d",i++); } A.5 B. 6 C. 4 D. Compiler error Q.18 Which of the following can not be used as Identifier ? A.Letters B.Digits Q.19 In an assignment statement C.Underscores D Spaces a=b; Which of the following statement is true? A. The variable a and the variable b are equal. B. The value of b is assigned to variable a but the later changes on variable b will not effect the value of variable a C. The value of b is assigned to variable a and the later changes on variable b will effect the value of variable a D. The value of variable a is assigned to variable b and the value of variable b is assigned to variable a. Q.20 Evaluate ! (1&&!(0||1)). A. True B. False C. Unevaluatable D. 0