Quiz 1 in Data Structure and Algorithm

Who is the father of C language?
Dennis Ritchie
Steve Jobs
James Gosling
Rasmus Lerdorf
Which of the following is not a valid C variable name?
Int number;
float rate;
Int variable_count;
Int $main;
All keywords in C are in ____________
LowerCase letters
UpperCase letters
CamelCase letters
None of the mentioned
Which of the following is true for variable names in C?
They can contain alphanumeric characters as well as special characters
Variable names cannot start with a digit
It is not an error to declare a variable to be one of the keywords(like goto, static)
Variable can be of any length
High level language is a .?
Language which is difficult to understand and not human readable.
Language with big program size.
Language with small program size.
Human readable like language.
Which program outputs "Hello World.." .?
Main() { scan("Hello World.."); }
Main() { print("Hello World.."); }
Main() { printf("Hello World.."); }
Main() { scanf("Hello World.."); }
C language was invented in which laboratories.?
Uniliver Labs
IBM Labs
AT&T Bell Labs
Verizon Labs
C language was invented to develop which Operating System.?
Android
Linux
Ubuntu
Unix
A C program is a combination of.?
Statements
Functions
Variables
All of the above
Which is valid C expression?
Int my_num = 100,000;
Int my_num = 100000;
Int my num = 1000;
Int $my_num = 10000;
Which of the following cannot be a variable name in C?
Volatile
True
friend
Export
What is an example of iteration in C?
For
While
Do-while
All of the mentioned
Correct way of commenting a single line is.?
/*printf("Hello C.."); printf("How are you.");
//printf("Hello C.."); printf("How are you.");
/*printf("Hello C.."); printf("How are you.");*/
/printf("Hello C..");/ printf("How are you.");
What is an Identifier in C Language.?
Name of a Function or Variable
Name of a Macros
Name of Structure or Union
All the above.
Choose correct statements
A constant value does not change. A variable value can change according to needs.
A constant can change its values. A variable can have one constant value only.
There is no restriction on number of values for constants or variables.
Constants and Variables can not be used in a singe main function.
Find an integer constant.
3.145
34
"125"
None of the above
Find a Floating Point constant.
12.3E5
12e34
125.34857
All the above.
Choose a right statement.
Int myage = 10; int my_age = 10;
Int myage = 10; int my,age = 10;
int myage = 10; int my age = 10;
All are right
Each statement in a C program should end with.?
Semicolon ;
Colon :
Period . (dot symbol)
None of the above.
What is the other name for C Language ?: Question Mark Colon Operator.?
Comparison Operator
If-Else Operator
Binary Operator
Ternary Operator
Choose a syntax for C Ternary Operator from the list.
Condition ? expression1 : expression2
condition : expression1 ? expression2
Condition ? expression1 < expression2
Condition < expression1 ? expression2
What is the output of the C statement.?
4
3
5
2
Choose a correct statement regarding C Comparison Operators.
(x == y) Is x really equal to y. (x != y) Is x not equal to y.
(x < y) Is x less than y (x > y) Is x greater than y
X <= y) Is x less than or equal to y. (x >= y) Is x greater than or equal to y
All the choices
__________ are reserved words that have special meaning in the C language.
Keywords
Variables
Comments
Syntax
In C language _______ are the names given to variables, constants, functions, and user-defined data.
identifiers
Keywords
Variables
Syntax
{"name":"Quiz 1 in Data Structure and Algorithm", "url":"https://www.quiz-maker.com/QPREVIEW","txt":"Who is the father of C language?, Which of the following is not a valid C variable name?, All keywords in C are in ____________","img":"https://www.quiz-maker.com/3012/CDN/82-3888719/data-struc1.jpg?sz=1200-00000000000829705300"}
Make your own Survey
- it's free to start.