Week 1 Flashcards
Program
A program is a sequence of instructions that specifies how to perform a computation on computer hardware.
Programming
The process of breaking down a large, complex task into smaller and smaller subtasks.
Method
A method is a named sequence of statements.
What is the relation between class name and file name?
The name of the class has to match the name of the file it is in
What are comments?
The line that begins with two slashes (//) is a comment, which is a bit of English text that explains the code.
What are the advantages of high-level languages?
- It is much easier to program in a high-level language.
- High-level languages are portable, meaning they can run on different kinds of computers with few or no modifications.
Which two kinds of programs translate high-level languages into low-level languages?
Interpreters and compilers.
What is an Interpreter?
An interpreter reads a high-level program and executes it, meaning that it does what the program says. It processes the program a little at a time, alternately reading lines and performing computations.
What is a compiler?
A compiler reads the entire program and translates it completely before the program starts running.
What is source code?
The high-level program is called the source code.
What is the translated program called?
The translated program is called the object code, or the executable.
What is an algorithm?
An algorithm is a sequence of steps that specifies how to solve a problem. Some algorithms are faster than others, and some use less space in computer memory.
What is Computer Science?
Computer science is the science of algorithms, including their discovery and analysis.
What are bugs? And what is debugging?
For historical reasons, programming errors are called bugs, and the process of tracking them down and correcting them is called debugging
What is a Variable?
A variable is a named location in memory that stores a value.