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
erastovalidia [21]
1 year ago
7

What is wrong with the following code? correct the bugs to produce the following expected output: first = [3, 7] second = [3, 7]

they contain the same elements.
Computers and Technology
1 answer:
AVprozaik [17]1 year ago
7 0

public class ArrayError {    

public static void main(String[] args) {      

int[] first = new int[2];        

first[0] = 3;        

first[1] = 7;        

int[] second = new int[2];

What is the bug in computer?

  • In computer technology, a bug is a coding error in a computer program.
  • We consider a program to also include the microcode that is manufactured into a microprocessor.)
  • The process of finding bugs -- before users do -- is called debugging.

first = [ 3,7 ]

second = [ 3 , 7]

They contains the same elements.

Process finished with exit code 0.

Learn more about bug

brainly.com/question/24124347

#SPJ4

<u>The complete question is -</u>

What is wrong with the following code? Correct the bugs to produce the following expected output: first = [3, 7] second = [3, 7] They contain the same elements. lype your solution here: 1 int[] first new int [2]; 2 first [0] 3; 3 first [1] 7; 4 int [ ] second = new int [2]; 5 second [0] = 3; 6 second [1] = 7; 8// print the array elements 9 System.out.println("first" first); 10 System.out.println("second"second); 12 // see if the elements are the same 13 if (first - second) I 14 System.out.println("They contain the same elements."); 15 else 16 System.out.println("The elements are different."); 17 h

You might be interested in
Which of the following phrases describes top-down processing
soldier1979 [14.2K]

Answer:

B. The effect that our experiences and expectations have on perception

Explanation:

Top-down processing refers to how our brains make use of information that has already been brought into the brain by one or more of the sensory systems. Top-down processing is a cognitive process that initiates with our thoughts, which flow down to lower-level functions, such as the senses.

Top-down processing is when we form our perceptions starting with a larger object, concept, or idea before working our way toward more detailed information. In other words, top-down processing happens when we work from the general to the specific—the big picture to the tiny details.

5 0
3 years ago
Help please will give brainliest!!!!!!!!!
Shkiper50 [21]

Answer:

Take a String.

Convert it into array of characters.

Apply for loop till length of char array.

Using isDigit() method we can check the digits in string.

If isDigit() will return true then print that index value.

That digit is in char form. ...

Using sum variable, we will sum it.

Explanation:

4 0
3 years ago
Which type of database program is Microsoft Access 2016?
nadya68 [22]

Answer:

O relational

Explanation:

If I'm wrong I'm so so sorry! But form my research it keeps saying its relational.

If I'm right please give me brainliest I really need it to level up so please help me!

If you don't know how to give brainliest there should be a crown underneath my answer you just have to click it.

Thank you and have a wonderful night,morning,afternoon/day! :D

6 0
3 years ago
Read 2 more answers
Different between internet and email​
pentagon [3]

Answer:

The internet allows you to connect with people and information around the world. The internet is more broad and could include searching things up or message-based websites. Emails is more specific, with it being when you send someone a message (called an email) on a mail website (that allows you to get messages from other people, websites, etc.)

Explanation:

In my answer.

5 0
3 years ago
Knowing what you know now about frequency analysis, would you feel comfortable sending your password over the Internet using a s
Vikki [24]
According to my opinion, NO, I'd not feel comfortable.

Substitution ciphers in the world of encryption can be cracked very easily. By looking for patterns like one letter words, double letter patterns, and knowing rules such as all words must contain at least an a, e, i, o, u or y, you are probably able to decipher this with so much ease. While this information and the frequency of letters used in the encrypted message might be helpful, it might not be a perfect process.


8 0
3 years ago
Read 2 more answers
Other questions:
  • The order in which statements are executed during a program run. Answer 1 The first part of a compound statement begins with a k
    12·1 answer
  • What type of attack is targeted against a smaller group of specific individuals, such as the major executives working for a manu
    9·1 answer
  • Why is it important to back up data on a computer before you burn-in test the cpu?
    9·1 answer
  • CHALLENGE ACTIVITY 2.15.1: Reading and outputting strings. Write a program that reads a person's first and last names, separated
    11·1 answer
  • And computers are the most commonly seen microcomputers.
    10·1 answer
  • The __________ logical operator works best when testing a number to determine if it
    12·1 answer
  • In 4-bit two's complement representation, what is the binary encoding of the number -5?
    8·1 answer
  • You are seeking a way to store computer files so you have backup copies anywhere you go.? Which one of the secondary storage typ
    11·1 answer
  • Write a C++ program that produces a simple personalized adventure game called Lost Fortune about a band of explorers that finds
    12·1 answer
  • Fort Nite is the best u can’t say it’s not
    13·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!