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
miv72 [106K]
3 years ago
7

Write a recursive, int -valued function, len, that accepts a string and returns the number of characters in the string .

Computers and Technology
1 answer:
vodka [1.7K]3 years ago
7 0
Without knowing the language, it's pretty imposible to write it.  Once you start thinking recursively, it's not a difficult problem.

While you're recursing, pass the string without the first character.
The base case would be a null string which would return 0.
The unwind would just add one and return that.
You might be interested in
Help me!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!​
Virty [35]

Answer: the body shape is skinny

4 0
3 years ago
Events and conditions that happen within an organization that are somewhat easier to deal with when responding to change are cal
IgorC [24]
These are called abstractions. They can be created by functions, if statements, or on event structures.
3 0
3 years ago
Examine the efficiency the various recovery algorithms used in deadlock handling
sineoko [7]

Solution:

The process of transaction can guarantee the reliability of business applications. Locking resources is widely used in distributed transaction management (e.g; two phase commit, 2PC) to keep the system consistent. The locking mechanism, however, potentially results in various deadlocks. In service oriented architecture, the deadlock problem becomes even worse because multiple transactions try to lock shared resources in the unexpectable way due to the more randomicity of transaction requests, which has not been solved by existing research results. In this paper, we investigate how to prevent local deadlocks, caused by the resource competition among multiple sub-transactions of a gl obal transaction, and global deadlocks from the competition among different global transactions. We propose a replication based approach to avoid the local deadlocks, and a timestamp based approach to significantly mitigate the global deadlocks. A general algorithm is designed for both local and global deadlock prevention. The experimental results demonstrate the effectiveness and efficiency of our deadlock prevention approach. Further, it is also proved that our approach provides higher system performance than traditional resource allocation schemes.

This is the required answer.

4 0
3 years ago
Regarding the Internet of Things (IoT), a business involved in utilities, critical infrastructure, or environmental services can
jeka94

Answer:

A. true

Explanation:

Based on the information provided within the question it can be said that the statement is completely true. This is because, traffic-monitoring applications have the main function of monitoring and analyzing the flow of traffic of one or various different items. Which can be applied to the business involving utility, infrastructure, and environmental services by monitoring the specific items regarding each business. Therefore making sure that enough product is entering or leaving each business as it is suppose to. As well as providing stock analysis and defective product alerts.

6 0
4 years ago
6. In cell K4, create a formula using the IF function to calculate the interest paid on the mortgage (or the difference between
AVprozaik [17]

Answer:

a. =IF(H4>0,12*$D$5-J4,0)

Explanation:

a. =IF(H4>0,12*$D$5-J4,0)

If( H4>0 is the logical test,

12*$D$5-J4 is [value_if_true]

0 is [value_if_false]

b. Referencing to the above formula in (a), which is the required formula which should be typed in cell K4.

Absolute referencing of cell D5 means that this will not change while extending this formula to the entire column. Whereas, since cell H4 and J4 have relative cell referencing, these will change relatively as we extend the formula to the entire column.

5 0
4 years ago
Other questions:
  • Open a command prompt on PC1. Issue the command to display the IPv6 settings. Based on the output, would you expect PC1 to be ab
    7·1 answer
  • 4+4 act quick for brainliest
    10·2 answers
  • Given a double variable named areaofsquare write the necessary code to read in a value , the area of some square, into areaofsqu
    9·1 answer
  • A block level element begins on a new line and some space is usually added before and after it - True or False?
    13·1 answer
  • Which type of memory helps in reading as well as writing data? With the help of , a computer can read as well as write or modify
    11·3 answers
  • Office ____ is the current version of Microsoft Office for Mac operating systems.
    12·1 answer
  • One lap around a standard high-school running track is exactly 0.25 miles. Write the function miles_to_laps() that takes a numbe
    8·1 answer
  • Jason has decided to use his name on all the images to protect them from misuse. He has also decided to use the logo of his comp
    15·2 answers
  • What does a production proposal provide ?
    7·2 answers
  • What are the common uses of joysticks? ​
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!