This is about identifiers in a record referring to other records.
You can have many to one, one to one, many to many.
E.g., if you have two tables, Authors and Books, then a book record could have a reference to an author record. Since an author can write many books, this would be a many-to-one relationship.
Answer:
function sum(number) {
if (number == 1) {
return 1;
}
return number + sum(number -1);
}
Explanation:
This is a recursive function, it means that is a function that calls itself for example: if you call the function with sum(5) the process is :
sum(5)
|______ 5 + sum(4)
|_______ 4 + sum(3)
|______ 3 + sum(2)
|_____2 + sum(1)
|_____ 1
the result is 1+2+3+4+5 = 15
It loses power and most likely stops working
The algorithm is as follows:
1. Start
2. bottles = 0
3. While bottles != 500
3.1 Create bottle
3.2 bottle = bottle + 1
4. Switch off machine
5. Stop
Explanation:
This begins the algorithm
1. Start
This initializes bottles to 0
2. bottles = 0
The loop is repeated until 500 bottles is created
3. While bottles != 500
This creates a new bottle
3.1 Create bottle
This increments the number of bottles by 1
3.2 bottle = bottle + 1
This switches of the machine after all bottles are created
4. Switch off machine
End algorithm
5. Stop
THANKS
Answer:
- the Keyboard:
The keyboard is a handheld device used to input alphabet, numbers, symbols and characters to a monitor. It also houses the special manipulative and function keys.
- the Control Unit:
The control unit is a component of the CPU which directs the operation of the processor.
- the Printer:
The printer is an external hardware output device which takes electronic data stored on a device and creates a hard copy.