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
marin [14]
3 years ago
5

Implement a function that meets the specifications below.

Computers and Technology
1 answer:
astraxan [27]3 years ago
4 0
Let me help you!
Since you did not specify what progamming language to use, I will do it in JAVA :>

import javax.swing.JOptionPane

public class Sum //The name of your program is Sum
{
//Variable Declaration
int s, sum, fCONTROL, control;

control = Integer.parseInt(JOptionPane.showMessageDialog("Please enter how many times you want to enter a number));
for(fCONTROL = 0; fCONTROL < control; fCONTROL++) //This is a for loop
{
//INPUT STATEMENT
s = Integer.parseInt(JOptionPane.showInputDialog("Please enter a number));
//PROCESS STATEMENT
sum = sum + s;
}//End of for loop
//OUTPUT STATEMENT
if(sum%2==0 || sum%2!=0)
{
JOptionPane.showMessageDialog(sum);
}
else
JOptionPane.showMessageDialog("You did not input an integer!");

}//End of program

You can test this is JCreator; it works and i stand by it. Good luck!
You might be interested in
g Which statement is true about the difference between combinational logic circuits and sequential logic circuits? A) Combinatio
kogti [31]

Answer:

D.

Explanation:  

In combinational circuits, the current output values are always the same for the same set of input values, regardless the previous values.

We say that combinational circuits have no memory, or that the circuit has no feedback from the outputs.  

For sequential circuits, on the contrary, the current output values are not based in the current input values only, but on the previous output values as well.

So, the fact of having a defined set of input values at a given moment, doesn't guarantee which the output values will be.

We say that sequential circuits have memory, or that they have feedback from the outputs.

Examples of these type of circuits are R-S, J-K, D or T flip-flops.

4 0
3 years ago
NAT ________. allows a firm to have more internal IP addresses provides some security both allows a firm to have more internal I
algol13

Answer:

NAT provides some security but allows a firm to have more internal IP addresses

Explanation:

NAT ( network address translation) this is a process where a  network system usually a firewall  assigns a public IP address to an internal computer used in a private network. it limits the number of public IP address a company operating a private network for its computer can have and this is very economical also limits the exposure of the company's private network of computers. the computers can access information within the private network using multiple IP addresses but it is safer to access external information using one public IP address

5 0
3 years ago
I WILL GIVE BRANLIST
qaws [65]

Answer:

space alignment

Explanation:

I'm not sure just taking a guess cuz I'm bored lol

4 0
2 years ago
Read 2 more answers
Which of the following is FALSE? Select one: a. The fast-paced and collaboration-based business environment makes email less use
12345 [234]

Answer:

The Atos case demonstrates that it is possible to cut out e-mail entirely.

Explanation:

6 0
3 years ago
What affect did the Scopes trial have on the school curriculum in Tennessee?
Bad White [126]
D)It did not change the curriculum because Scopes lost the case.
4 0
3 years ago
Read 2 more answers
Other questions:
  • Define a function CoordTransform() that transforms its first two input parameters xVal and yVal into two output parameters xValN
    7·2 answers
  • Care and feeding for computer
    7·1 answer
  • An anagram is a word or a phrase made by transposing the letters of another word or phrase; for example, "parliament" is an anag
    7·1 answer
  • EASY POINTS what favorate food<br> so easy
    7·2 answers
  • What is the output of:<br><br> print (8 % 4)
    6·1 answer
  • If you can photoshop please text me i need help for my digital media class 7862381441
    9·1 answer
  • What best determines whether a borrower's interest rate on an adjustable rato loan goes up or down?
    13·2 answers
  • Camera work is at the center of video production. True or False?
    14·1 answer
  • Write the simplest statement that prints the following: 3 2 1 Go! python
    6·1 answer
  • What happened to China and India after they modernized their workforces by providing more training and education?
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!