LISP Questions & Answers – File Manipulation

This set of LISP Multiple Choice Questions & Answers (MCQs) focuses on “File Manipulation”.

1. Which translate the procedures into equivalent computer instructions?
a) File
b) Compile-file
c) Compiler
d) None of the mentioned
View Answer

Answer: b
Explanation: Compile-file is mainly used to translate the procedures into equivalent computer instructions.

2. Which primitive is used to create or modify a specified file?
a) File
b) Manipulation
c) ED
d) None of the mentioned
View Answer

Answer: c
Explanation: To create or modify a file, we can use ED primitive.

3. How the files are specified in lisp?
a) Strings
b) Characters
c) Booleans
d) None of the mentioned
View Answer

Answer: a
Explanation: Files are specified as strings, which is one lisp’s data type.
advertisement
advertisement

4. Which has its own convention for doing the basic maneuvers?
a) Lisp
b) Compiler
c) Lisp
d) Editor
View Answer

Answer: d
Explanation: Editors have their own convention for doing basic maneuvers.

5. To which value does the lisp compiler is evaluated?
a) File
b) String
c) Compile-File
d) None of the mentioned
View Answer

Answer: c
Explanation: Lisp compiler is used to evaluate a compile-file form.
Sanfoundry Certification Contest of the Month is Live. 100+ Subjects. Participate Now!

6. What is produced from compile-file?
a) Text file
b) Binary file
c) Lsp file
d) All of the mentioned
View Answer

Answer: b
Explanation: Compile-file produces a binary file full of unintelligible computer instructions expressed by a bit sequences.

7. What is the correct syntax form of the given statement?
a) (ed <file specification>)
b) (ef <file name>)
c) (ed <file location>)
d) All of the mentioned
View Answer

Answer: a
Explanation: Thus the syntax of ED primitive is given.
advertisement

8. What is the correct syntax form of the given statement?
a) (load <file>)
b) (load <file attributes>)
c) (load)
d) None of the mentioned
View Answer

Answer: b
Explanation: Load primitive is used to read from files.

9. What is the correct syntax form of the given statement?
a) (compile-file <target file specification>)
b) (compile <target file specification>)
c) (compile-file <source file specification>)
d) None of the mentioned
View Answer

Answer: c
Explanation: In Syntax; source file specification comes instead of target-file. So, compile-file <source file specification> is the correct syntax.
advertisement

10. Which is used to compile individual procedures?
a) Compile-file
b) ED
c) Compile
d) Load
View Answer

Answer: c
Explanation: Lisp provides a way to compile individual procedures by the use of compile.

Sanfoundry Global Education & Learning Series – LISP Programming Language.

advertisement
advertisement
Subscribe to our Newsletters (Subject-wise). Participate in the Sanfoundry Certification contest to get free Certificate of Merit. Join our social networks below and stay updated with latest contests, videos, internships and jobs!

Youtube | Telegram | LinkedIn | Instagram | Facebook | Twitter | Pinterest
Manish Bhojasia - Founder & CTO at Sanfoundry
Manish Bhojasia, a technology veteran with 20+ years @ Cisco & Wipro, is Founder and CTO at Sanfoundry. He lives in Bangalore, and focuses on development of Linux Kernel, SAN Technologies, Advanced C, Data Structures & Alogrithms. Stay connected with him at LinkedIn.

Subscribe to his free Masterclasses at Youtube & discussions at Telegram SanfoundryClasses.