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
astraxan [27]
2 years ago
7

What is wrong with each of the following code segments? int[] values; for (int i = 0; i < values.length; i++) { values[i] = i

* i; }
Computers and Technology
1 answer:
tino4ka555 [31]2 years ago
7 0

Answer:

values have been declared but not initialized nor allocated memory. So you are not allowed to use "values.length"

You might be interested in
HAS ANYONE HEARD OF THE GAME SCHOOL DAY
Musya8 [376]

Answer:

NO BUT IT SOUNDS FUN

Explanation:

I PROBABLY HAVE NOT HEARD OF IF BC IM HOMESCHOOLED :D

3 0
3 years ago
Which tool lets you increase the view, but not the size, of text, images, and other content?
blagie [28]
Use ctrl + or - or if in microsoft word, use the zoom tool
7 0
3 years ago
Its made up of a small memory chips on a card that can hold data in an electronic format​
valina [46]

The chip can allow you to have more data and more pictures so your phone does not become slow and messages and apps and more.

4 0
3 years ago
Please help me. It's due in 2 hours.
Neporo4naja [7]
1d 2b 3c 4a 5e 6f 7g
3 0
3 years ago
Write commands to carry out the following commands: a) Print all lines containing the string John. b) Print all lines where a wo
egoroff_w [7]

Answer:

see explaination

Explanation:

1.

1. grep 'John' FileName

2. grep '^\J' FileName

3. grep 'stopped$' FileName

4. grep -v -e 'was' FileName

5. grep -E '^(k|K)' FileName

2.

#print the message to create subdirectory

echo "Creating a subdirectory to copy current directory files into named 'sub'"

#create subdirectory

mkdir sub

echo "Directory successfully created"

#Copy the files in the current working directory to created subdirectory

echo "Copying files of current directory into newly created subdirectory"

rsync -a --exclude='sub' * sub

#display the message to copy the files

echo "Copying operation completed successfully"

echo "Now deleting the created subdirectory along with its contents"

rm -rf sub

#indicated the message completion of task

echo "Operation completed successfully."

3.

#prompt and read the first number

echo "Enter the first number: "

read x

echo "Enter the second number: "

read y

#Compute arithmetic operations and store in the

#respective variable

addition=$(($x + $y))

subtraction=$(($x - $y))

multiplication=$(($x * $y))

division=$(($x / $y))

#print the values

echo "Addition of $x and $y is $addition"

echo "Subtraction of $x and $y is $subtraction"

echo "Multiplication of $x and $y is $multiplication"

echo "Division of $x and $y is $division"

3 0
3 years ago
Other questions:
  • How many parameters go into the function sum, and how many return values come out of the function sum? function sum(first, secon
    6·1 answer
  • Which of the following likely comes last in developing a presentation outline
    6·2 answers
  • Can you get shocked from a breaker box?
    11·1 answer
  • 2. What is a cap? (0.5 points)
    9·1 answer
  • In a(n) __________ situation, a wireless device is configured to appear to be a legitimate access point, enabling the operator t
    5·1 answer
  • Renae wants to write a blog about her favorite sports stars. She wants the blog to be informative and visually appealing, so she
    13·2 answers
  • Create a Produceclass that hasan instance variable of type Stringfor the name, appropriate constructors, appropriate accessor an
    13·1 answer
  • How to program a game​
    7·2 answers
  • Anyone know what this is pls help
    11·1 answer
  • Drag each statement to the correct location.
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!