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
Elenna [48]
3 years ago
8

Which code snippet calculates the sum of all the even elements in an array values? Group of answer choices int sum = 0; for (int

i = 0; i < values.length; i++) { if ((values[i] % 2) == 0) { sum++; } } int sum = 0; for (int i = 0; i < values.length; i++) { if ((values[i] % 2) == 0) { sum += values[i]; } } int sum = 0; for (int i = 0; i < values.length; i++) { if ((values[i] / 2) == 0) { sum++; } } int sum = 0; for (int i = 0; i < values.length; i++) { if ((values[i] / 2) == 0) { sum += values[i]; } }
Computers and Technology
1 answer:
olganol [36]3 years ago
5 0

Answer:

The second one:

int sum = 0; for (int i = 0; i < values.length; i++) { if ((values[i] % 2) == 0) { sum += values[i]; } }

You might be interested in
What is java Encapsulation?​
mart [117]

Answer:e

Explanation: Encapsulation is one of the four fundamental OOP concepts. The other three are inheritance, polymorphism, and abstraction. The other three are inheritance, polymorphism, and abstraction. Encapsulation in Java is a mechanism of wrapping the data (variables) and code acting on the data (methods) together as a single unit

4 0
3 years ago
Complete the sentence.
mojhsa [17]

Answer:

its a network

Explanation:

that is how it is called

7 0
3 years ago
Peace is a fruit of the Spirit that comes from _______ .
Harman [31]
I believe your answer should be A. 

7 0
3 years ago
How do I connect my CSS file and HTML page together? it's just not wanting to work for me. 
kiruha [24]
In the <head> part of your HTML, you reference the CSS like this:

<link<span> rel="stylesheet" type="text/css" href="thecss.css"</span><span>>
</span>
If it is still not working, there could be many kinds of mistakes. Take it one step at a time and start simple, or share your HTML and CSS so we can have a look.
4 0
4 years ago
Which of the following “invisible” marks represents an inserted tab?
maria [59]
I believe C is the answer.
8 0
3 years ago
Read 2 more answers
Other questions:
  • Which of the following characteristics relates to authentication header (AH)? It is a document that defines or describes compute
    11·1 answer
  • What is the purpose of the chart feature in word?
    15·1 answer
  • What is the leading use of computers
    15·2 answers
  • What development in operating systems happened between the years 1990 and 2000?
    15·1 answer
  • Can an iphone user see when an android user is typing
    10·2 answers
  • I have been charged for brainly plus yet I still have to watch ads why? What do I do?
    12·2 answers
  • Security breaches are easier to address with which payment form?
    11·2 answers
  • 5. Nadia wants to calculate the total interest, which is the total amount of the payments minus the loan amount. In cell F6, ent
    8·1 answer
  • Because his father _____ his ten-speed bike away to punish him for his failing grades, the boy sulked for two days.
    11·1 answer
  • Mention and discuss specific professional ethics related to augmented reality, artificial intelligence, and the internet of thin
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!