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
zimovet [89]
3 years ago
8

After you create an array variable, you still need to ____ memory space.

Computers and Technology
1 answer:
Svetllana [295]3 years ago
6 0
This is a little tricky. I would say reserve. It would help to know what programming language and class this is for because a lot of times when you create an array variable the memory is put onto the stack and you as the programmer do not reserve memory space. Now on the other hand, if you are programming in C and you want to create an array variable and put it on the heap then you would reserve memory space on the heap.
You might be interested in
Which of the following is a good precaution to take when making online purchases? (1 point)
Fantom [35]

Answer:

A.

Explanation:

A is the answer..

This is because you can use a private browser for safety precautions so no hackers would target you and steal your personal information. Also the other options make no sense at all. Option B states that you can use the same strong password for all online accounts and that's not good. It's not recommended because hackers or other people on the dark web can hack into your accounts and steal your data. Option C states that you must make sure http: and an open padlock displays on the address bar. This means that your connection is insecure and people can track you down. Option D is a good thing to do but option A is the best option overall. It's the right step to take when making online purchases <3

5 0
3 years ago
Write a program that reads in 10 numbers from the user and stores them in a 1D array of size 10. Then, write BubbleSort to sort
Diano4ka-milaya [45]

Answer:

The solution is provided in the explanation section.

Detailed explanation is provided using comments within the code

Explanation:

import java.util.*;

public class Main {

//The Bubble sort method

public static void bb_Sort(int[] arr) {  

   int n = 10; //Length of array  

   int temp = 0; // create a temporal variable  

   for(int i=0; i < n; i++){  

         for(int j=1; j < (n-i); j++){  

           if(arr[j-1] > arr[j]){  

               // The bubble sort algorithm swaps elements  

               temp = arr[j-1];  

               arr[j-1] = arr[j];  

               arr[j] = temp;  

             }  

         }            

         }  

        }

 public static void main(String[] args) {

   //declaring the array of integers

   int [] array = new int[10];

   //Prompt user to add elements into the array

   Scanner in = new Scanner(System.in);

   //Use for loop to receive all 10 elements

   for(int i = 0; i<array.length; i++){

     System.out.println("Enter the next array Element");

     array[i] = in.nextInt();

   }

   //Print the array elements before bubble sort

   System.out.println("The Array before bubble sort");

   System.out.println(Arrays.toString(array));

   //Call bubble sort method

   bb_Sort(array);  

               

   System.out.println("Array After Bubble Sort");  

   System.out.println(Arrays.toString(array));

 }

}

8 0
3 years ago
# q7 - create function readFileFirstLast() to meet the conditions below
MAVERICK [17]

Answer:

See explaination

Explanation:

def readFileFirstLast(filename):

# doc string

''' Function accept the filename and opens the fle

and reads all lines and strips new line character and

stores first and last in a string and return that string'''

#eception handle if file not found

try:

#opening the file

f = open(filename)

#reading the first line and striping the ne line

string = f.readline().strip()

#iterating until last line

for line in f:

pass

#concate the last line after strip the new line character to the string

string = string + " " + line.strip()

#return the string

return string

except:

#if file not found

return "File not found"

#taking the file name from user

filename = input("Enter a file name: ")

#printing the doc string in function

print("\ndoc_sting: \n"+ readFileFirstLast.__doc__+"\n")

#printing the returned string by calling the readFileFirstLast()

print("output string :")

print(readFileFirstLast(filename))

3 0
3 years ago
BRIANLIEST!!!!!!!!!!!!!!!!
oksano4ka [1.4K]

Answer:

First Line indent

Explanation:

should be correct

4 0
3 years ago
Read 2 more answers
_____ is a form of witty, amusing speech that is often used to bring people together.
Neporo4naja [7]

Answer:Informative

Explanation:

5 0
3 years ago
Read 2 more answers
Other questions:
  • He would like to get rid of the graph. What will accomplish
    8·1 answer
  • What is an (CR) Optical character recognition?
    13·2 answers
  • 1.
    13·1 answer
  • In order to make burger a chef needs the following ingredients one piece of chicken meat 3 lettuce leaves 6 tomato slices Write
    8·1 answer
  • In the view that follows, which field can't be updated create view example_2 as select invoice_number, invoice_date, invoice_tot
    13·1 answer
  • The term ____ describes primary storage devices that are implemented as microchips, can read and write with equal speed, and can
    8·1 answer
  • Choose the best type of loop for each situation.
    6·1 answer
  • Please help I really need it :(
    12·1 answer
  • Please hurry!
    15·2 answers
  • Fill in the blank with the correct term.
    10·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!