Answer:
oneMore(oneMore(oneMore(oneMore(oneMore(0)))))
Explanation:
- As a function has been explained which when given an integer results as a next integer. oneMore(given-integer)= next integer
- As we are restricted to use 0 only and can't use operators like + - * /.
- We have to obtain a value 5
- So doing step-by-step:
(oneMore(0))=1
(oneMore(oneMore(0)))=2
(oneMore(oneMore(oneMore(0))))=3
(oneMore(oneMore(oneMore(oneMore(0)))))=4
oneMore(oneMore(oneMore(oneMore(oneMore(0)))))=5
Answer:
The first value of i is 0 and last value of i is 20.
Explanation:
The following are the description of a given loop.
- In this problem, there are two loops one is the internal loop and the other is the external loop
- In the outer loop, the value of " i" is initialized with "0" So the first value is printed 0 in the console.
- For one value of "i" all the inner loop is executed.
- The loop is executed is less equal to 20 that's why the last value of "i" is printed 20 in the console window.
A symbol or set of characters in a programming statement whose value can be changed