Which of the following keyword is used to declare the header file?
- include
- exclude
- string
- namespace
What does a default header file contain?
- prototype
- implementation
- declarations
- pointing
Header files in C contain
- Compiler commands
- Library functions
- Header information of C programs
- Operators
Identify the wrong statement
- putchar(65)
- putchar('x')
- putchar("x")
- putchar('\n')
Which header file is essential for strcmp() function?
- string.h
- strings.h
- text.h
- strcmp.h
Which of the following is a key word used for a storage class
- printf
- external
- auto
- scanf
An Ampersand before the name of a variable denotes
- Actual Value
- Variable Name
- Address
- Data Type
What are the types of C Preprocessor Directives.?
- Macros
- Conditional Compilation
- File Inclusion
- All the above
Processor Directive in C language starts with.?
- $ symbol (DOLLAR)
- @ symbol (At The Rate)
- & symbol (Ampersand)
- # symbol (HASH)
Preprocessor in C language works on.?
- DOTC file (.c)
- DOTEXE file (.exe)
- DOTH file (.h)
- DOTCP file (.cp)
What is the another name for .C file.?
- Executable code
- Source Code
- Distributable Code
- Macro code
What is the keyword used to define a C macro.?
- def
- definition
- define
- defy
What is the output of C program with #define.?
#define CVV 156
int main()
{
int a=10;
a = a*CVV;
printf("CVV=%d",a);
return 0;
}
- 0
- 1560
- 1560
- Compiler error
What is the C keyword used to create global Constants.?
- constant
- definition
- def
- define
Choose a correct C statement about #define statement.?
#define CVV 156
- CVV is called Macro Expansion. 156 is called Macro Template.
- CVV is called Macro Expansion. 156 is also called Macro Expansion.
- CVV is called Macro Template. 156 is called Macro Expansion.
- None of the above
What is the output file generated after processing a .C file.?
- .h file
- .exe file
- .cp file
- .bak file
How do you safeguard your .C file code from copying by outside developers or world.?
- Encrypt a C file and share
- Obfuscate a C file and share
- Scramble a C file and share
- Convert to Exe and share.
What is the output of C program with macros.?
#define ERRMSG printf("Some error.");
int main()
{
printf("JAR.");
ERRMSG;
return 0;
}
- JAR.
- JAR.ERRMSG
- JAR.Some error.
- Compiler error
What is the output of C program with macros.?
#define ERRMSG(a) printf("Error=%d",a);
int main()
{
ERRMSG(10);
return 0;
}
- ERRMSG(10)
- Error=
- Error=10
- Compiler error
What is the output of C program.?
#define LOGIC(a,b) (a==b)
int main()
{
if(LOGIC(5,5))
{
printf("SAME ");
}
return 0;
}
- SAME
- LOGIC(5,5)
- 5==5
- Compiler error
What is the output of C program.?
#define LOOP(a) for(int i=1;i<=a;i++) \
{printf("%d ",i);}
int main()
{
LOOP(5);
return 0;
}
- 5
- 5 5 5 5 5
- 1 2 3 4 5
- Compiler error
What is the output of C program.?
#define TANK(a) a*10+2
int main()
{
int a = TANK(2)*2;
printf("%d",a);
return 0;
}
- 44
- 22
- 24
- Compiler error
What is the file extension of expanded source code of .C file after preprocessing.?
- .e file
- .h file
- .l file
- .p file
What is the command to preprocess a C file manually.?
- pp abc.c
- cpp abc.c
- exp abc.c
- op abc.c
What is the C Preprocessor directive to be used to add a header file or any file to existing C program.?
- #add
- #present
- #include
- $include