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
Blizzard [7]
3 years ago
10

Write a recursive function sumAll that accepts an integer argument and returns the sum of all the integers from 1 up to the numb

er passed as an argument. For example, if 50 is passed as an argument, the function will turn the sum of 1, 2, 3, 4, ..50.
Computers and Technology
1 answer:
slavikrds [6]3 years ago
8 0

Answer:

int sumAll(int n)//function definition.

{

   if(n==1)//if condition.

   return 1;

   else//else condition.

   {

       return n+sumAll(n-1);//return the value and call the function in recursive manner.

   }

}

Explanation:

  • The above-defined function is a recursive type function that is written in the c language, which holds the if and else condition.
  • When the user passes the largest value from 1, then the else condition will be executed which adds the largest value and pass the value after the decrement of the value as an argument.
  • When the value will become 1, then the function if-block will be executed which returns the value and ends the calling function recursively.
You might be interested in
A technically qualified individual who may configure firewalls and IDPSs, implement security software, diagnose and troubleshoot
sineoko [7]

Answer:

Security technician

Explanation:

Security technicians are responsible for fixing, planning, and implementing the IT and computer security system of organisations by making sure the safety and security of the data and information of the clients as well as the employees that make daily use of the systems

Security technicians administer security access to the clients and employees of the organization and are responsible for being up to date with the latest IT security technology developments.

7 0
3 years ago
What is the internet?
aliya0001 [1]
What you're currently on. or a global computer network providing a variety of information and communication facilities, consisting of interconnected networks using standardized communication protocols.
7 0
3 years ago
Read 2 more answers
Explain why regular system cleanup is vital to ensuring the operating system runs efficiently.
Oksanka [162]
Cleaning up a system helps clear up the space on the drives. It may also clear up processor usage, ram usage if you uninstall programs that automatically started when the system booted. You may also delete some unwanted programs in the process.
5 0
3 years ago
A cell's address, its position in the workbook, is referred to as a ________________ when it is used in a formula.
Inga [223]

Answer:

A cell's address, its position in the workbook, is referred to as a <u>cell reference</u>  when it is used in a formula.

5 0
2 years ago
What is database design?
finlep [7]

Answer: Database design is the model created of data/information for any particular organization .the relation between the information and which data is to be stored is the most important factor for designing .These parameters are decided by the designer of the database.

After the decision of the designed the data is invoked in the database .The data representation in the theoretical manner is known as ontology.The classification and relation defining is the purpose of the database design.

3 0
3 years ago
Other questions:
  • Create a class named BaseballGame that contains data fields for two team names and scores for each team in each of nine innings.
    12·1 answer
  • ________ are devices used to send data between two networks.
    11·1 answer
  • Describe the tools that are required to accomplish each step in the data management process.
    15·2 answers
  • Claudia has a bachelors degree in computer information systems and she has learned to use some popular software testing tolls wh
    13·2 answers
  • Write a program "addnumbers.c" where it takes as many arguments as the user includes as command line arguments and calculates th
    11·1 answer
  • In what way , if any, can your social media presence affect your chances of getting a job in social media?
    8·1 answer
  • The illustration shows different types of text language.
    5·2 answers
  • /*this function represents
    8·2 answers
  • What power points feature will you use to apply motion effects to different objects of a slide
    5·1 answer
  • How many passes will it take to find 30 using a binary search?
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!