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
laila [671]
1 year ago
14

How do you create a function in C++

Computers and Technology
1 answer:
MArishka [77]1 year ago
7 0

Answer:

1. Declaration: the return type, the name of the function, and parameters (if     any)

2. Definition: the body of the function (code to be executed)

Explanation:

You might be interested in
A tablet computer is a low-cost, centrally managed computer with no internal or external attached drives for data storage.
Norma-Jean [14]

Answer: False

Explanation: Tablet computer is a type of the smartphone which is portable and has computer functions. It can be used for the data accessing, videos, pictures etc. They also have a internal storage for the storing of the data.So, the statement given is false.

Thin client is the device that persist these features mentioned in the question.It is a small computer without fan and any hard-drive for the storage.It is device that has a connection along with a network,.

5 0
2 years ago
To navigate to a new web page for which you know the url, type that url in the browser’s ____ bar and press enter.
Slav-nsk [51]
It would be to type the url in the browser's address bar
3 0
3 years ago
Write a program that will prompt the user to enter an integer. The program should square the number and then print the squared n
Kay [80]

Answer:

// here is code in C++.

#include <bits/stdc++.h>

using namespace std;

// function to compute sum and product

void square(int input)

{

   // variable to store the square of number

   long long squ_num;

   calculate the square of number

   squ_num=pow(input,2);

   // print the output

   cout<<"square of "<< input<<" is: "<<squ_num<<endl;

   

}

// driver function

int main()

{

   int n;

   // read the number until user enter 0

   do{

       cout<<"enter a number!! (0 to stop):";

     // read the input from user

       cin>>n;

       // call the function to calculate square of input number

       square(n);

       

   }while(n!=0);

 

return 0;

}

Explanation:

Declare a variable "n" to read the input number from user.Call the function  square() with parameter "n".In this function, it will calculate the square  of the input number and print it.This will repeat until user enter 0 as  input.Program will ends when user give 0 as input.

Output:

enter a number!! (0 to stop):5                                                                                                                                

square of 5 is: 25                                                                                                                                            

enter a number!! (0 to stop):7                                                                                                                                

square of 7 is: 49                                                                                                                                            

enter a number!! (0 to stop):11                                                                                                                              

square of 11 is: 121                                                                                                                                          

enter a number!! (0 to stop):0

3 0
3 years ago
The first operating systems, in the 1950s, were designed for _____.
Leya [2.2K]

They were designed for batch processing.

Explanation

In the beginning, around the 1940s, electronic computers were built without Operating systems. These computers could not do basic calculations, read and write data, or run programs. Setbacks such as these led to the development of operating systems.

The first one was introduced in the early to mid-1950, and it relied on the batch processing systems to facilitate submission of data into groups. Rather than processing tasks individually, this system processed tasks in batches. Upon the completion of a job, the batch would head over to the OS’s software. The software would then dump the state of the active task and open the next one. This helped reduce operator intervention and time wastage.

Learn more:

  • How does operating systems work when passing parameters to kernel. brainly.com/question/6062548

#LearnwithBrainly

7 0
3 years ago
The advantages of the DecimalFormat class compared with the NumberFormat class include Group of answer choices
Anon25 [30]

Answer:5. only A and B(precise control over the number of digits to be displayed and control over the presence of a leading zero)

Explanation: DECIMAL FORMAT CLASS is a subclass of Number format class specifically made to format parsing decimal Numbers. It is capable of formating both ARABIC, WESTERN AND INDIC DIGITS. It has a unique Attribute of control over the number of digits to be displayed and control over the presence of a leading zero.

NUMBER FORMAT CLASS is the class for formatting parsing numbers it helps to format According to Specific locale.

3 0
3 years ago
Other questions:
  • . Which game was the most popular free download in Apple®’s app store by January 2014, despite poor reviews and plagiarism accus
    14·2 answers
  • Henry has to create software that manages a database of all his clients of his firm. He wishes to run software on another comput
    10·2 answers
  • Using the college registration example from section 6.7.3 as a starting point, do the following:
    14·1 answer
  • What can be done to improve the security of business uses of the Internet? Give several examples of ecurity measures and technol
    9·1 answer
  • A technician mistakenly uninstalled an application that is crucial for the productivity of the user.
    6·1 answer
  • Select the correct answer.
    8·2 answers
  • Assume that the following variables have been defined in a program: int x = 10; int y = 20; int z = 30; Write a cout statement t
    11·1 answer
  • Draw a flow chart that accepts mass and volume as input from the user. The flow chart should compute and display the density of
    8·1 answer
  • Consider the following instructions for a game element: Move Forward If not at end, move forward Else stop This is an example of
    10·1 answer
  • 5. An external CSS file is saved with D. Answer the following questions. 1. Explain the purpose and advantages of using CSS.​
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!