CMSC 104 FINAL EXAM(with complete solutions)
What is an algorithm, as defined in our class? correct answers An algorithm is a finite set of instructions that can be executed and direct a terminating activity. Since when have algorithms been studied? correct answers They've been studied for ages. What are some examples of algorithms as discussed in class? correct answers Some examples are Euclidean's algorithm and sorting algorithms (insertion sort and bubble sort). What is a text editor? correct answers A text editor is program that allows us to edit plain text files. What are the various text editors we have used or discussed in this class? correct answers Some examples are xemacs, emacs, and nano. What are the various LINUX/UNIX commands available to us and what do they do? correct answers mkdir -- makes a directory cd -- takes you to the home directory cd (path) -- takes you to a new path ls -- lists all files and subdirectories of the current directory cat (filename) -- displays all of the file's contents rm (filename) -- removes a file What is C? correct answers C is a programming language What computer language precedes C? correct answers C is preceded by B What are the 3 control structures to C? correct answers SEQUENCE -- using operators (addition, subtraction, etc.) SELECTION -- if/else statements, switch statements, etc. REPETITION -- loops: for, while, do-while What are the stages of compiling a program? correct answers (1) preprocessing (2) compiling (3) linking
Información del documento
- Subido en
- 23 de mayo de 2024
- Número de páginas
- 13
- Escrito en
- 2023/2024
- Tipo
- Examen
- Contiene
- Preguntas y respuestas