69 lines
2.7 KiB
Markdown
69 lines
2.7 KiB
Markdown
![]() |
You can find it on [quizlet](https://quizlet.com/nl/449627571/fundamentals.flash.cards/).
|
||
|
|
||
|
### A ...........(1) is a relationship between input and output values such that any input is associated with only one output. If the output can be determin8ed algorithmically from the input, the relationship is said to be .............(2)
|
||
|
1. function
|
||
|
2. computable
|
||
|
|
||
|
### Select all of the following statements that are false
|
||
|
1. No one has discovered a problem that cannot be solved by a Turing machine.
|
||
|
2. No one has discovered a problem that cannot be solved by a Turing machine.
|
||
|
3. The Bare Bones programming language would not be a universal language if the clear statement were removed.
|
||
|
|
||
|
### Suppose the variable X in the following Bare Bones program has the value 3 when execution begins.
|
||
|
|
||
|
```
|
||
|
clear Y;
|
||
|
decr X;
|
||
|
while X not 0 do;
|
||
|
decr X;
|
||
|
incr Y;
|
||
|
end;
|
||
|
```
|
||
|
A. What will be the value of X when the program terminates? **0**
|
||
|
B. What will be the value of Y when the program terminates? **2**
|
||
|
|
||
|
### If a solution with time complexity Θ(n2) is known to exist, then the problem is known to be in which of the following?
|
||
|
O(n2).
|
||
|
<sub>(What the fuck is the difference)</sub>
|
||
|
|
||
|
### The class of problems known as NP is so named because it is composed of which of the following?
|
||
|
Non-deterministic polynomial problems
|
||
|
|
||
|
|
||
|
### The precise time complexity of which of the following problems has not yet been established by researchers?
|
||
|
The traveling salesman problem
|
||
|
|
||
|
### Which of the following algorithms represents an optimal solution (in terms of time complexity) for sorting a list?
|
||
|
Merge sort
|
||
|
|
||
|
### Which of the following is the most precise classification of a problem X?
|
||
|
X is in Θ(n2).
|
||
|
<sub>WHAT THE FUCK IS Θ AND WHY IS IT DIFFERENT FROM THE BIG O</sub>
|
||
|
|
||
|
### Which of the following statements is true (select all that are correct)
|
||
|
1. All Bare Bones programs that do not contain a while statement are self-terminating.
|
||
|
2. No Bare Bones program is both self-terminating and not self-terminating
|
||
|
|
||
|
|
||
|
### Which of the following best describes what the following Bare Bones program does?
|
||
|
```
|
||
|
copy X to Z;
|
||
|
clear X;
|
||
|
incr X;
|
||
|
while Z not 0 do;
|
||
|
clear X;
|
||
|
decr Z;
|
||
|
end;
|
||
|
```
|
||
|
|
||
|
If the starting value of X is 0, it sets the value of X to 1. Otherwise, it sets the value of X to 0.
|
||
|
|
||
|
### Which of the following statements is false?
|
||
|
The halting problem can be solved only by using a universal programming language.
|
||
|
|
||
|
### Which of the following systems does not process the same computational capabilities as the others?
|
||
|
Universal programming languages
|
||
|
|
||
|
### Select all of the following statements that contradict the Church-Turing thesis.
|
||
|
1. All functions are computable.
|
||
|
2. Some functions that are not computable by Turing machines are computable by other means
|