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
Yakvenalex [24]
3 years ago
11

Write a pseudocode to add the first 100 even numbers.

Computers and Technology
1 answer:
Allushta [10]3 years ago
6 0

Even numbers are numbers whigh are divisible by 2. Therefore, the first even number is 2. A pseudocode which adds the first 100 even numbers can be written thus :

counter = 0

sum = 0

interval = 2

while counter < 100 :

sum = sum + interval

interval += 2

counter +=1

print(sum)

  • A counter takes count of the number of values summed

  • Initializes a variable which holds the sum of even values

  • Since even numbers are divisible by 2; every factor ; increase every added value by 2

  • The program ends once counter is 100

Learn more : brainly.com/question/25327166

You might be interested in
Write any two reasons why files are stored in folders​
iogann1982 [59]

Answer:

Explanation:

The answer is The tree structure suggests the main benefit of folders: to organize your files. You can create folders to store and organize your pictures, your documents, your videos, and so on. Folders are also used to separate the files created by different users.

4 0
3 years ago
Read 2 more answers
What is the most important basic property of melody? Why?​
enot [183]

Most good melodies restrict their basic range to no more than an octave-and-a-half. Most good melodies use repeating elements. Listeners should be hearing certain melodic intervals, rhythms and other musical shapes repeating throughout the melody

5 0
3 years ago
Write a Comparator that compares String objects by the number of words they contain. Consider any nonwhitespace string of charac
Readme [11.4K]

Answer:

import java.util.Scanner;

public class num12 {

   public static void main(String[] args) {

       Scanner in = new Scanner(System.in);

       System.out.println("Enter the first String");

       String word1 = in.nextLine();

       System.out.println("Enter the second String");

       String word2 = in.nextLine();

       System.out.println("Enter the third String");

       String word3 = in.nextLine();

       //Remove all white spaces

        String cword1 = word1.replace(" ","");

       String cword2 = word2.replace(" ","");

       String cword3 = word3.replace(" ","");

       //Comparing the string by their lengths

       if(cword1.length()>cword2.length()&&cword1.length()>cword3.length()){

           System.out.println(word1+" Is the longest");

       }

       else if(cword2.length()>cword1.length()&&cword2.length()>cword3.length()){

           System.out.println(word2+" Is the longest");

       }

       else{

           System.out.println(cword3+" Is the longest");

       }

   }

}

Explanation:

Using Java Programming Language

Use the Scanner Class to obtain the String values from the user

Save them in different variables

Use the replace() method in java to remove white space from any of the string entered

Using if and else statements compare the lengths of the strings (word.length()) returns the length of the word.

Print out the word that is longest

NOTE I have compared three Strings, comparing two would have been more straigth forward

8 0
4 years ago
Charles would like to visit a specific page on the World Wide Web. How should he do it?
Ulleksa [173]
Charles should type in Https:web.com but should visit the sites containing ".org,".Gov'" and make sure they've been updated recently. 
 He should also check for authors and dates. 
 Or he can go to a library online if he is doing a research paper.


4 0
3 years ago
What is the left area of a slide called in an electronic presentation
Natasha2012 [34]

The left area of a slide is called the "slide pane" in an electronic presentation. It displays the thumbnails of all the slides in a presentation window.

3 0
3 years ago
Read 2 more answers
Other questions:
  • Which internet explorer 11 feature enables it to correctly display pages that were developed using older technologies?
    14·1 answer
  • 1. The trucks hauling asphalt have a maximum capacity of 5 US tons (10,000 lbs) 2. The standard road lane is 12 feet wide. 3. As
    14·1 answer
  • What is the name of the symbol that is used to classify and categorize information?​
    10·2 answers
  • What will the following segment of code output?
    7·1 answer
  • Which of the following statements is false? The ARPANET is the precursor to today’s Internet. Today’s fastest Internet speeds ar
    11·1 answer
  • A selected graphic appears surrounded by a(n) ______, which has small squares and circles around its edges.
    7·1 answer
  • Three Strings someone help
    15·1 answer
  • What do you expect the future trends of an operating system in terms of (a) cost (b) size (c) multitasking (d) portability (e) s
    12·1 answer
  • Which of these is not an application software?
    6·2 answers
  • Join my me et.goo gle.etj-dovn-kds​
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!