C Programming Unit-1 Test-2

Quiz
•
Computers
•
University
•
Hard
PRASHANT ATMAKURI
Used 14+ times
FREE Resource
20 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Which of the following is not a valid C variable name?
int number;
float rate;
int variable_count;
int $main;
Answer explanation
Since only underscore and no other special character is allowed in a variable name, it results in an error.
2.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Which of the following is true for variable names in C?
They can contain alphanumeric characters as well as special characters
It is not an error to declare a variable to be one of the keywords(like goto, static)
Variable names cannot start with a digit
Variable can be of any length
3.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is short int in C programming?
The basic data type of C
Qualifier
Short is the qualifier and int is the basic data type
All of the mentioned
4.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Which of the following typecasting is accepted by C language?
Widening conversions
Narrowing conversions
Widening & Narrowing conversions
None of the mentioned
5.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Which of the following is NOT possible with any 2 operators in C?
Different precedence, same associativity
Different precedence, different associativity
Same precedence, different associativity
All of the mentioned
6.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Property which allows to produce different executable for different platforms in C is called?
File inclusion
Selective inclusion
Conditional compilation
Recursive macros
7.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
What will be the output of the following C code?
int y = 10000;
int y = 34;
printf("Hello World! %d\n", y);
Hello World! 34
Hello World! 10000
Hello World! followed by a junk value
Compile time error
Create a free account and access millions of resources
Similar Resources on Wayground
20 questions
BS TEST2

Quiz
•
University
25 questions
GNIDOC ROUND 1

Quiz
•
University
20 questions
Programming in C(1)

Quiz
•
University
15 questions
BASIC C QUIZ

Quiz
•
University
20 questions
ROUND 1 QUIZ FOR 1ST YEAR

Quiz
•
University
15 questions
Coding and Debugging

Quiz
•
University
25 questions
Code Carnival

Quiz
•
University
15 questions
BASIC C PROGRAMMING QUIZ

Quiz
•
University
Popular Resources on Wayground
50 questions
Trivia 7/25

Quiz
•
12th Grade
11 questions
Standard Response Protocol

Quiz
•
6th - 8th Grade
11 questions
Negative Exponents

Quiz
•
7th - 8th Grade
12 questions
Exponent Expressions

Quiz
•
6th Grade
4 questions
Exit Ticket 7/29

Quiz
•
8th Grade
20 questions
Subject-Verb Agreement

Quiz
•
9th Grade
20 questions
One Step Equations All Operations

Quiz
•
6th - 7th Grade
18 questions
"A Quilt of a Country"

Quiz
•
9th Grade