

MCQOPTIONS
Saved Bookmarks
This section includes 746 Mcqs, each offering curated multiple-choice questions to sharpen your Technical Programming knowledge and support exam preparation. Choose a topic below to get started.
351. |
Which option of gcc enables compiler’s all warning messages? |
A. | -Wall |
B. | -War |
C. | -Warn |
D. | None of the mentioned |
Answer» B. -War | |
352. |
The -H option of gcc |
A. | prints the name of each header file used |
B. | is used to include header file |
C. | ignores the header file which are not required by source code |
D. | none of the mentioned |
Answer» B. is used to include header file | |
353. |
What is the job of -Werror option in gcc? |
A. | it avoids all the errors present in the source code |
B. | it makes all warnings into errors |
C. | it stores all the errors of source code into a seperate file |
D. | none of the mentioned |
Answer» C. it stores all the errors of source code into a seperate file | |
354. |
Which option of gcc inhibit all warning messages? |
A. | -w |
B. | -x |
C. | -y |
D. | -z |
Answer» B. -x | |
355. |
The option -fsyntax-only of gcc |
A. | checks the code for syntax error |
B. | checks the code for fatal error |
C. | checks the code for syntax & fatal error |
D. | None of the mentioned |
Answer» B. checks the code for fatal error | |
356. |
Which gcc option turns off certain features of gcc that are incompatible with ISO C89? |
A. | -ansi |
B. | c-ISO |
C. | -ver |
D. | none of the mentioned |
Answer» B. c-ISO | |
357. |
The -v option of gcc |
A. | print the commands executed to run the stages of compilation |
B. | version of the gcc compiler |
C. | all of the mentioned |
D. | none of the mentioned |
Answer» B. version of the gcc compiler | |
358. |
Which gcc option stops compilation process after preprocessing stage? |
A. | -e |
B. | -f |
C. | -E |
D. | -F |
Answer» D. -F | |
359. |
Which gcc option includes debugging info in the generated object code? |
A. | -g |
B. | -c |
C. | -p |
D. | none of the mentioned |
Answer» B. -c | |
360. |
Which one of the following command creates the executable file a.out? |
A. | gcc -o sanfoundry.c |
B. | gcc sanfoundry.c |
C. | gcc -o a.out |
D. | gcc a.out |
Answer» C. gcc -o a.out | |
361. |
Which one of the following provides all dependencies in the makefile? |
A. | $^ |
B. | $* |
C. | $: |
D. | none of the mentioned |
Answer» B. $* | |
362. |
When a target of makefile fails to execute |
A. | make does not executes any other target dependent on it |
B. | it returns a status |
C. | make does not executes any other target dependent on it & it returns a status |
D. | none of the mentioned |
Answer» D. none of the mentioned | |
363. |
Which one of the following is not a valid makefile directive? |
A. | if |
B. | elif |
C. | endif |
D. | none of the mentioned |
Answer» E. | |
364. |
Macros for the makefile can be defined in |
A. | makefile |
B. | command line |
C. | both makefile and command line |
D. | none of the mentioned |
Answer» D. none of the mentioned | |
365. |
In the makefile the target and dependencies are separated by the character |
A. | – |
B. | : |
C. | / |
D. | none of the mentioned |
Answer» C. / | |
366. |
Which one of the following can be used to specify the directory to search the dependencies and target files? |
A. | VPATH |
B. | CPATH |
C. | FPATH |
D. | None of the mentioned |
Answer» B. CPATH | |
367. |
Which one of the following is used for the target filename in the makefile? |
A. | $@ |
B. | $* |
C. | $? |
D. | none of the mentioned |
Answer» B. $* | |
368. |
In makefile the comment begins with the character |
A. | $ |
B. | #` |
C. | /* |
D. | none of the mentioned |
Answer» C. /* | |
369. |
Running “make” command without the arguments starts the target ____ in the makefil |
A. | “.phony” |
B. | “clean” |
C. | first |
D. | none of the mentioned |
Answer» D. none of the mentioned | |
370. |
If we want to execute the makefile by just giving the “make” command, makefile should be named as |
A. | Makefile |
B. | makefile |
C. | MAKEFILE |
D. | None of the mentioned |
Answer» B. makefile | |
371. |
If make command is executed as “make -j 2”, then |
A. | two jobs will run simultaneously |
B. | only two will be executed |
C. | it will give an error |
D. | None of the mentioned |
Answer» B. only two will be executed | |
372. |
Which make command option ignores all errors in commands executed to remark files? |
A. | -i |
B. | -j |
C. | -k |
D. | -l |
Answer» B. -j | |
373. |
If we want to get the exit status that specified targets are up to date or not, we have to execute the make command with option |
A. | -q |
B. | -r |
C. | -s |
D. | -t |
Answer» B. -r | |
374. |
Which option of make command print the commands that would be executed, but do not execute them? |
A. | -m |
B. | -n |
C. | -o |
D. | -p |
Answer» C. -o | |
375. |
The makefile starts executing from |
A. | first target |
B. | first target whose name starts with “.” |
C. | first target whose name does not starts with “.” |
D. | none of the mentioned |
Answer» D. none of the mentioned | |
376. |
As we type “make” command on the terminal |
A. | make reads the makefile in the current directory |
B. | make reads the makefile in the parent directory |
C. | make reads the makefile in the predefined environment variable |
D. | none of the mentioned |
Answer» B. make reads the makefile in the parent directory | |
377. |
What is phony target in the makefile? |
A. | the target which is not a filename |
B. | the target which is a filename |
C. | the target which does not used for compilation |
D. | none of the mentioned |
Answer» B. the target which is a filename | |
378. |
What is makefile? |
A. | makefile describes to the make command that how to compile the program |
B. | makefile contains various statements related with the compilation of target |
C. | makefile contains various statements |
D. | none of the mentioned |
Answer» B. makefile contains various statements related with the compilation of target | |
379. |
The /sbin/sysctl command is used to |
A. | view kernel settings in the /proc/sys/ directory |
B. | set kernel settings in the /proc/sys/ directory |
C. | automate kernel settings in the /proc/sys/ directory |
D. | all of the mentioned |
Answer» E. | |
380. |
What is /proc/self ? |
A. | a directory |
B. | link to the currently running process |
C. | it allows a process to look itself without having to know its process ID |
D. | all of the mentioned |
Answer» E. | |
381. |
The file /proc version shows the version of ______ used in the system. |
A. | kernel |
B. | gcc |
C. | both kernel and gcc |
D. | none of the mentioned |
Answer» D. none of the mentioned | |
382. |
The file /proc/locks displays the file currently locked by the |
A. | kernel |
B. | user |
C. | superuser |
D. | none of the mentioned |
Answer» B. user | |
383. |
/bin/dmesg picks the messages from |
A. | /proc/kmesg |
B. | /sbin/klogd |
C. | both /proc/kmesg and /sbin/klogd |
D. | none of the mentioned |
Answer» B. /sbin/klogd | |
384. |
The file /proc/kcore displays a size of |
A. | RAM |
B. | RAM plus 4 KB |
C. | RAM plus 8 KB |
D. | None of the mentioned |
Answer» C. RAM plus 8 KB | |
385. |
The file /proc/execdomains lists the |
A. | execution domains currently supported by the linux kernel |
B. | all domains of all processes |
C. | registered ISA DMA channel in use |
D. | none of the mentioned |
Answer» B. all domains of all processes | |
386. |
For the system having one processor, the processor identifying number in the file /proc/cpuinfo is |
A. | 0 |
B. | 1 |
C. | 2 |
D. | 3 |
Answer» C. 2 | |
387. |
Which file shows the parameter passed to kernel at the time of starting? |
A. | /proc/apm |
B. | /proc/cmdline |
C. | both /proc/apm and /proc/cmdline |
D. | none of the mentioned |
Answer» C. both /proc/apm and /proc/cmdline | |
388. |
Which file is used primarily for diagnosing memory fragmentation issues ? |
A. | /proc/buddyinfo |
B. | /proc/meminfo |
C. | /proc/apm |
D. | none of the mentioned |
Answer» B. /proc/meminfo | |
389. |
The directory /proc/net contains information about |
A. | Different network system compiled into the system |
B. | IP address of the system |
C. | MAC address of the system |
D. | None of the mentioned |
Answer» B. IP address of the system | |
390. |
The files of /proc directory are |
A. | stored in secondary memory |
B. | generated by the kernel |
C. | stored in secondary memory & generated by the kernel |
D. | none of the mentioned |
Answer» C. stored in secondary memory & generated by the kernel | |
391. |
Accessing the file /proc/meminfo gives the different result each time because |
A. | memory usages is always fluctuating |
B. | a new process id is assigned |
C. | logical address is different from the physical address |
D. | none of the mentioned |
Answer» B. a new process id is assigned | |
392. |
Proc files are |
A. | read-only files |
B. | read-write files |
C. | both read-write and read-only files |
D. | none of the mentioned |
Answer» D. none of the mentioned | |
393. |
Most files and directories within /proc are 0 bytes in size because |
A. | proc filesystem exists only as a reflection of the in-memory kernel data structure |
B. | these files contains very only one or two instructions |
C. | proc filesystem doesn’t exists only as a reflection |
D. | none of the mentioned |
Answer» B. these files contains very only one or two instructions | |
394. |
With the help of proc filesystem |
A. | kernel and kernel modules can send the information to processes |
B. | process information can be accessed |
C. | kernel modules can send the information to processes & process information can be accessed |
D. | none of the mentioned |
Answer» D. none of the mentioned | |
395. |
The file /proc/[PID]/mountinfo contains |
A. | major minor numbers of device files |
B. | root of the mount within the filesystem |
C. | mount point relative to the process’s root |
D. | all of the mentioned |
Answer» E. | |
396. |
Which one of the following command will print the environement of process 1? |
A. | cat /proc/1/environ |
B. | cat /proc/bin/1/env |
C. | cat /proc/1/var/env |
D. | none of the mentioned |
Answer» B. cat /proc/bin/1/env | |
397. |
The command “cd /proc/10/cwd” provides the |
A. | current working directory of process having PID 10 |
B. | current status of the process having PID 10 |
C. | current version of the filesystem |
D. | none of the mentioned |
Answer» B. current status of the process having PID 10 | |
398. |
/proc/tty contains the information about |
A. | current terminal |
B. | all terminals |
C. | both current & all terminals |
D. | none of the mentioned |
Answer» B. all terminals | |
399. |
The file /proc/swaps contains the |
A. | list of active swap partitions |
B. | sizes of the swap partitions |
C. | priorities of the swap partitions |
D. | all of the mentioned |
Answer» E. | |
400. |
The buddy algorithm handles the |
A. | Memory fragmentation |
B. | DHCP server |
C. | Routing |
D. | None of the mentioned |
Answer» B. DHCP server | |