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
harina [27]
3 years ago
7

Write a java program named SumThousand The program adds all the number from 1 to 1000 together and print out the sum

Computers and Technology
1 answer:
My name is Ann [436]3 years ago
6 0

Answer:

The program in Java is as follows:

public class SumThousand  {

   public static void main(String args[]) {

     int sum=0;

     for(int i =1;i<=1000;i++)

         sum+=i;

     

     System.out.println("Sum = " + sum);

   }

}

Explanation:

This initializes sum to 0

int sum=0;

This iterates from 1 to 1000

     for(int i =1;i<=1000;i++)

This calculates the required sum

         sum+=i;

     

This prints the calculated sum

     System.out.println("Sum = " + sum);

   

You might be interested in
Hi i need help with something:(
AleksandrR [38]

Answer: what do  you need help with?

Explanation:

4 0
2 years ago
Read 2 more answers
Zoe runs a sports media website that caters to fans of many different types of sports. She's starting a Google Display Ads campa
Alex

Answer:

Affinity Audiences allow her to reach sports enthusiasts.

Explanation:

Affinity Audiences are usually TV-style audiences normally designed with the aim of trying to connect advertisers with the type of customers they are searching for online at any point in time. Google Ads uses this feature via the browser history of the user and the time spent on pages and then associates the users browser with a category of interest.

8 0
3 years ago
Eq-20 why is the height of a vhf radio antenna important
masya89 [10]
Reasons why the height of a VHF radio antenna is important is because VHF radios work by the line of sight principle.
Line of sight
its a line from observers eye to a distant point.its a line between two points specifically the straight path between a transmitting antenna (as for radio or television signals) and receiving antenna when unobstructed by the horizon.
7 0
3 years ago
Read 2 more answers
Which 3 statements are true about journal entries? (Quick Books)
Sonbull [250]

Answer:

1.Total debits must equal total credits

4.When posting to the accounts receivable account, you must specify a customer

5.You can post to multiple accounts receivable and/or accounts payable accounts in the same journal entry

Explanation:

1.

A Journal entry follows the concept of double-entry. In the double-entry principle, a debit entry equals a credit. After posting all the required entries total debits are equal to the total credits.

4.

The business makes sales to customers. Some sales are made on cash or some are made on credit. In the case of credit sales, the receivables are made. To record the credit sale entry we must specify the customer in the debit entry against the credit entry of sales.

5.

in recording the credit sales or purchases multiple receivable or payable accounts can be used and a single entry of sales of purchases can be posted against these accounts. For example

Journal Entry with multiple receivables accounts.

DR. Customers A $1,000

DR. Customers B $2,000

DR. Customers C $3,000

CR. Sales ______$6,000

6 0
3 years ago
5. Create a vector called to20 that goes from 1 to 20 (use the range notation). Now create a variable called end that goes from
Lady_Fox [76]

Answer:

creating vector:

code:  

to20 <-c(1:20) #creating to20 vector

end <-c(40:50) #creating end vector

to50 <-c(to20,21:30,end) # creating to50 vector

print(to50) # printing to50 vector

Explanation:

8 0
3 years ago
Other questions:
  • Henry bought a new card for capturing television on his computer. When he finished going through the packaging, though, he found
    5·1 answer
  • Describe one activity that belongs to the organizing phase software engineering.
    8·2 answers
  • What is a browser? Give one example
    8·2 answers
  • Can someone please help me? I have no clue what any of this is and how I'm going to find out 15 examples of these. It's due some
    5·1 answer
  • You have been allocated a class C network address of 211.1.1.0 and are using the default subnet mask of 255.255.255.0 how many h
    14·1 answer
  • The ________ is responsible for the Internet's domain name system and the allocation of IP addresses.
    12·1 answer
  • Determina la cilindrada total Vt en un motor de 4 cilindres de 83,6 mm de diàmetre per 91 mm de cursa.
    8·1 answer
  • What is the function of HTML?
    6·2 answers
  • Film’s importance in today’s economy?
    12·1 answer
  • Taking control of admin functionality and misusing sensitive data that are unauthorized to access are due to.
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!