1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Mariulka [41]
3 years ago
14

Assume the availability of a function named oneMore. This function receives an integer and returns one more than its parameter.

So, pass oneMore( 12) and it will return 13. DO NOT DEFINE this function-- just assume it is available. YOUR TASK: write an expression whose value is 5 but in your expression you can only use the integer literal 0. You can not use anything with the digits 1-9 and you cannot use any arithmetic operators like + - * /. But you can use 0 and you can make calls to the function oneMore.
Computers and Technology
1 answer:
jek_recluse [69]3 years ago
7 0

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

You might be interested in
What are Manuscript signs​
mihalych1998 [28]

Answer: See explanation

Explanation:

Manuscript signs, refers to the marks or the symbols that are used within a manuscript in order to show the necessary corrections which should be made during the preparation of a document.

Manuscript formatting is vital as it makes the manuscript easier to assess. In a situation whereby manuscripts are poorly formatted, it can be turned down by agents and publishers.

5 0
3 years ago
Which of the following electronic payments is ideal for micropayments?
timama [110]

Answer:

B. smart cards

Explanation:

3 0
3 years ago
Read 2 more answers
Which of the following is most likely to include technical vocabulary?
Step2247 [10]
<span>C. a scientific article</span>
6 0
3 years ago
Is a MODEM required for Internet Connectivity ?<br> Yes<br> No
Pie

Answer:

you can connect to the wifi on your device it will say you are connected but the wifi will not be connected to the internet so you will be able to do nothing on it without the modem

Explanation:

4 0
3 years ago
Read 2 more answers
Which of the following is true about operating system.
zalisa [80]

Answer:

google kis kam ka hai us se puch lo

7 0
3 years ago
Other questions:
  • You’ve received a tarball called data79.tar from a colleague, but you want to check the names of the files it contains before ex
    15·1 answer
  • Why should you not perform any personal grooming task while driving?
    5·2 answers
  • 5. The stage of engine operation when both the intake and exhaust valves are closed is the _______ stage.
    5·1 answer
  • Give two separate print statements: one will print your name, the other will print your major. Ensure that both will print on th
    15·1 answer
  • John was carrying on at the water cooler the other day, trying to show off his knowledge of networking. He claimed that the comp
    10·1 answer
  • A franchise restaurant is attempting to understand if customers think their service is good day-to-day by summarizing a series o
    10·1 answer
  • Explain how arrays are stored in memory? Show how arr [5] is stored in the memory. Assume each memory location is one byte long
    6·1 answer
  • Does anyone have 2.19.4 Guess a number 2.0 code for codehs?
    8·1 answer
  • the image on the right was prooduced by a computer. it shows a complex molecu;e consisting of many atoms. what would be an advan
    6·1 answer
  • A web site that contains large numbers of misspelled words and grammatical errors fails which of these general criteria?
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!