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
MissTica
3 years ago
15

Write a statement that defines an array of four integers named miles. The array should be initialized with the values 1, 5, 9, a

nd 22.
Computers and Technology
1 answer:
VashaNatasha [74]3 years ago
3 0

Answer:

int miles[4] = {1, 5, 9, 22};

Explanation:

Given:

Initialized values = 1, 5, 9, and 22

Find:

Defines an array of four integers

Computation:

int miles[4] = {1, 5, 9, 22};

You might be interested in
​Most online auction sites offer merchandise that is the property ____, much as an auctioneer would at a public auction.
statuscvo [17]

Answer:

The answer is "of others".

Explanation:

The auction site has become a service, in which auction clients or members are using the internet to buy or sell goods and services.  

  • These sites use the different auction sites, which include forums for consumers, operated by multiple software, that's sale forms also recognized as a virtual auction.
  • These sites sell items owned by the others, which is an auctioneer does at a public auction.
5 0
3 years ago
Red is the longest color of the visible spectrum <br> T or F
MAVERICK [17]
True! the farthest it can go is infared which we cannot see.
5 0
4 years ago
Read 2 more answers
A recursive method may call other methods, including calling itself. A recursive method has:
kap26 [50]

Answer:

Hence the answer is given as follows,

Explanation:

Base Case:-  

If (num == 0) //This is the base case for the given recursive method  

return 1;  

If(num % 2!=0) checks whether num is odd.  

The above condition is true for all odd numbers and false for even numbers.  

if the remainder is not equal to zero when we divide the number with 2 then it is odd.  

The method:-  

The above recursive method calculates the product of odd numbers up to the given range(that is num)  

For num=5   => 15(5*3*1).  

For num=7   => 105(7*5*3*1).  

For num=10 => 945(9*7*5*3*1).

8 0
3 years ago
apple and adobe are in disagreement about the use of __________ to create apps for the iphone and ipad?
Fantom [35]
Apple and Adobe are in disagreement about the use of using Adobe Flash Player on iOS devices such as the iPhone and iPad
4 0
3 years ago
Write a full class definition for a class named Averager, and containing the following members: An data member named sum of type
RUDIKE [14]

Answer:

//program in java.

import java.io.*;

class Averager {

   public static int sum;

   public static int count;    

   //constructor to initialize values

   Averager(){

       sum = 0;

       count = 0;

   }

   //Method to return Sum

   public static int getSum(){

       return sum;

   }

   //Method to add the value passed in parameter

   public static void add(int num){

       sum=sum+num;

       count=count+1;

   }

   //Method to return Count

   public static int getCount(){

       return count;

   }

   //Method to return Average

   public static double getAverage(){

//type casting is used

       return (double) sum / (double) count;

   }      

   //User Driven Input method to run the program

public static void main (String[] args)throws IOException {

    //Using BufferedReader class for reading input

    InputStreamReader x = new InputStreamReader(System.in);

    BufferedReader inp = new BufferedReader(x);

    int n;

    do{

 System.out.println("Enter your choice");

 System.out.println("1.getSum()");

 System.out.println("2.add()");

 System.out.println("3.getCount()");

 System.out.println("4.getAverage()");

 System.out.println("5.Exit");

 n=Integer.parseInt(inp.readLine());

 switch(n)

 {

     case 1 : int s = getSum();

              System.out.println("The Sum is " + s);

              break;

     case 2 : System.out.println("Enter the number to add");

              int num;

              num=Integer.parseInt(inp.readLine());

              add(num);

              break;

     case 3 : int c = getCount();

              System.out.println("The Count is " + c);

              break;

     case 4 : double avg = getAverage();

              System.out.println("The Average is " + avg);

              break;

     default : break;

 };

    }while(n!=5);

    System.out.println("Exiting");

}

}

Explanation :

Average() constructor is used for initialization. Method getSum() will return the value of sum. Method getCount() will return the count and method getAverage() will return the average. The average will be of double type. User driver input is designed to call the methods as and when required.

Input:

Enter your choice

1.getSum()

2.add()

3.getCount()

4.getAverage()

5.Exit

1

Output:

The Sum is 0

7 0
3 years ago
Other questions:
  • Please draw a diagram of a complete graph with 5 vertices (K5), its adjacency matrix and adjacency list representations.
    13·1 answer
  • How did larissa describe the process of roberto's release in chapter 4 and what was her answer to jonas question
    5·1 answer
  • Describe a strategy for avoiding nested conditionals. Give your own example of a nested conditional that can be modified to beco
    15·1 answer
  • Marilyn needs help exporting her spreadsheet as a few different types of files. She needs to know exactly how her file should be
    11·1 answer
  • .To remove data from a table we use the DELETE verb? (true/false)
    13·1 answer
  • Uhm.....why do we nessairly have to take computer classses
    11·2 answers
  • The storage device which is not usually used as secondary storage is 1 point a) Semiconductor Memory b) Magnetic Disks c) Magnet
    6·1 answer
  • How to change my age on this app
    10·2 answers
  • Weaknesses about ICT Technician
    9·1 answer
  • Higher Order Functions used for simulations of dice rolls. Definition: An n-sided dice function takes no arguments and always re
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!