CH 2.B PROGRAMS/INSTRUCTIONS IN C Flashcards
Define c program.
c program is a collection of functions supported by c library
state the use of following in program:
main()
main is an function in program which states the line from which the execution of program begins. every program must has main function.
every program consist atleast one function in program and that function has to be ____.
main()
state the use of following in program:
{}
{ brace bracket. denotes start of the function main. } denotes end of the function main(). includes instructions
state the use of following in program: //
comment lines. non executable statements which are been ignored by the compiler. used for better understanding of the program by the compiler. helps in debugging and testing a program.
program within {} is called the ____.
body of function main()
main() body contains ___.
instructions to perform a task
true or false: comment lines can be nested
false
true or false: comment lines can be placed anywhere in the program
true
true or false: /* */ is used to write comment over one line.
false. // is used
____ must end with a semicolon
statements
____ is a executable function used for printing the output in the program.
printf()
___ ,___are a predefined function
printf()
scanf()
what is an predefined function?
functions which are already been written nd compiled.
state the use of following in program: /n
backslash character constant which prints the output on nextline
true or false: the statements in c must be in specific order/position
false. c program can be in any position/order.
c programs can be in uppercase, lowercase. but lowercase letters are for ___
symbolic constants
c programs must be in ___
lowercase
a c program must be written in ___ os and compiled in ___ compiler while executing a program in PC
msdos,dos
a program must be created and edited in any wordprocessing application in ___ mode.
non document
one must run a program file with ___ extension
.c
sucessful compilation will generate _____ of your program.
object file
while compiling a program, c compiler points out(reports) ___.
syntax errors
state the process of execution of the program.
- the program is been written. a program can be written and edited in any word processing document in non document mode.
- the program is been debugged
- program is been compiled
- object file of the program is been generated
- object file is been linked to execution file and file has .exe extension.
- . program is been run the program file now has .c extension. the program can be run in msdos file by typing the name.