Computing Science and Programming Flashcards

You may prefer our related Brainscape-certified flashcards:
0
Q

What are five steps to problem solving?

A
  1. Identify the problem
  2. Possible solutions l
  3. Analyze and select a solution
  4. Execute the solution
  5. Determine if the solution has fix the problem
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
1
Q

What is three aspects of computation?

A
  1. Design and analysis of algorithm
  2. Formalization of algorithm as programs
  3. Development of computational device for executing programs
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is the most important skill for a computer scientist?

A

Problem solving

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Define problem solving

A

The ability to formulate a problem, think of creative solutions and express solutions as clearly and as accurately as possible.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Define algorithm

A

An algorithm is a finite sequenced set of unambiguous steps that once executed, produces a result

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Define program language

A

Is a language that allows us to specify detailed instructions that a computer can understand and execute

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What does computing mean?

A

Field of studying computer

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Define decomposition in computer science

A

To decompose is to break down into “finer” details. Ex. Decomposing a vague solution into a more detailed and descriptive solution

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Define programming/software development

A

The science and art of creating computer programs for the purpose of solving problems

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Order the following instructions in chronological order
• Input Data
• structure data and represent it in a solution
• Output - identify data produced by solution

A
  1. Input Data
  2. Output - identify data produced by solution
  3. Structure data and represent it in a solution
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What are the five ways to express an algorithm?

A
  1. Using a natural language like English
  2. Pseudocode
  3. Flow chart
  4. Video
  5. Diagram (pictures)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is input?

A

Receive data from keyboard, mouse, file, network or etc

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is output? Or examples of it

A

Display data on screen, save it in the file, etc

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is an example of a high level language?

A

Python

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What are alternative names for low level languages?

A

Machine language or assembly language

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Computers can only execute programs written in which languages? High- level or low-level languages?

A

Computers can only run programs written in low-level languages (machine language)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Define machine language

A

Encoding of instructions in binary so that they can be directly executed by the computer

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

What is the one disadvantage of high-level language?

A

It takes time to process before executing

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

What are four advantages of using high-level languages?

A
  • less time to write it
  • shorter and easier to read it
  • portable, which means it can be used on different computers with few to no modifications
  • more likely to be correct
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

What are the two programs or softwares that changes high-level languages into low-level languages?

A

Interpreters and compilers

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

What is the difference between compiler and interpreter?

A

Interpreter process bits and bits of high-level language while executing it.

Compilers process the whole high-level language before executing it.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

Define source code

A

Source code is the program (high-level language) before it is processed/translated and contains instructions

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

Define object code

A

A program that has been processed or translated

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

Define executable

A

Object code

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

Define byte code

A

Object code

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
Q

What is a virtual machine?

A

A program that interprets low-level languages

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
26
Q

Fun fact: after a program is interpret, the language is called interpret language

A

🍔

27
Q

What are two ways to use Python IDLE?

A

Python interpreter Shell mode and Python program editor

28
Q

What is the advantage of Python interpreter?

A

One gets immediate feedback

29
Q

Fun fact: In shell mode,

A

It express Python expression into Python shell

30
Q

What does&raquo_space;> mean and what is it called

A

Python prompt&raquo_space;>

It indicates that the interpreter is ready for instructions

31
Q

Fun facts: files that contain Python programs

A

End with .py

32
Q

Define pseudocode

A

The use of natural language and computer language together

33
Q

Define computer programming

A

Finite sequenced set of computer programming language instructions

34
Q

What are two things programming language is made out of?

A

Vocabulary (building block)
And
Syntax rules (grammar)

35
Q

What is programming language also called?

A

Formal language

36
Q

What is the first generation of programming language?

A

Machine language

37
Q

What is the second generation of programming language?

A

Assembly languages

38
Q

What is the third generation of programming language?

A

High-level language

39
Q

What is the fourth generation of programming language?

A

4GL

40
Q

Which of the following is CPU dependent?

  1. Machine language
  2. High-level language
  3. Assembly language
A

1 and 3

Machine language and assembly language

41
Q

Define mnemonic

A

Label

42
Q

Define error-prone

A

High chance of making a mistake

43
Q

What is the advantage to machine language?

A

The algorithm is already translated therefore it can be executed

44
Q

What are the disadvantage of assembly language and machine language?

A

Both are error-prone and tedious to read

45
Q

What is three differences between assembly languages and machine languages?

A
  1. Assembly language must be translated to machine language before execution.
  2. Assembly language express the instructions in a series of zeroes and ones like machine language but assembly language also load, store and halt. (Mnemonic)
  3. Assembly language is easier to read than machine language
46
Q

Define debug

A

Finding problems within programs or algorithms and fixing it

47
Q

How abstract is assembly language from machine language? 1 or 2 level away?

A

Assembly language is 1 level of abstraction away form machine language.

48
Q

True or false? High-level languages are abstract

A

True

49
Q

Object code is written in __________ _____________.

A

Object code is written in only machine language

50
Q

Define Scratch

A

Scratch is a block-based imperative, event-driven, dynamically-type and interpreted programming language.

51
Q

What are two things Syntax rule contain?

A

Token and structure

52
Q

Define token

A

Token are elements of languages. Examples are words, numbers and chemistry elements

53
Q

Define parsing

A

Analyzing structure

54
Q

What are the three differences between natural language and formal language?

A
  1. Natural languages are ambiguous while formal language is unambiguous (clear)
  2. Natural language has a lot of redundancy (more words than necessary) while formal language is brief and concise
  3. Natural language are full of idiom and metaphors while formal language means exactly what they say
55
Q

Define prose

A

Literal meaning of words

56
Q

Fun fact: natural language is like poetry while formal language is like prose

A

📖

57
Q

Which is more dense and harder to read? Formal language or natural language?

A

Formal language

58
Q

Fun fact: interactive mode

A

Is the same thing as interpreter mode

59
Q

Define script mode

A

A way of using the Python interpreter to read code from a script and run it

60
Q

What is the difference between script mode and interactive mode?

A

Script mode doesn’t automatically display results where as interactive mode gives immediate feedback.

61
Q

What are 4 steps of the execution flow?

A
  1. State problem
  2. Design algorithm+identify data
  3. Turn algorithm into program
  4. Test it
62
Q

Define print statement

A

An instruction that causes the Python interpreter to display a value on the screen

63
Q

Define bug

A

Error in program

64
Q

Define Python

A

Python is a text-based, interpreted, object-oriented, dynamically-type, high-level programming language

65
Q

Define script

A

A program stored in a file