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
raketka [301]
3 years ago
11

Write an algorithm and draw a flowchart to calculate2^4 using a loop approach?​

Computers and Technology
1 answer:
zlopas [31]3 years ago
8 0

Answer:

I'm not about to write a flow chart for you, but here's a quick demo of how to do it:

doPower(2, 4);

function doPower(base, power){

   var result = 1, p;

   for(p = 0; p < power; p++){

       result *= base;

   }

   return result;

}

That function will only work for positive integer exponents of course.

You might be interested in
What was the name of the first personal computer and what year was it introduced
Nadya [2.5K]

Answer:

IBM's own Personal Computer (IBM 5150) was introduced in August 1981, only a year after corporate executives gave the go-ahead to Bill Lowe, the lab director in the company's Boca Raton, Fla., facilities. He set up a task force that developed the proposal for the first IBM PC.

6 0
3 years ago
Linda is viewing the campaign report in her Google Ads account after successfully implementing conversion tracking tags for her
anyanavicka [17]

Answer:

Option 1 and Option 3 are correct.

Explanation:

Linda is displaying that marketing update within the Google Advertising profile after effectively installing transformation monitoring tags to its site. She saw that slightly two of her advertising are created by the following View-through transformations.

Thus, somebody seeing up towards Thirty seconds of such advertisements as well as anyone clicking on a portion of such advertising as View-through transformations.

6 0
3 years ago
John typed 545 words in 35 minutes, what is his typing speed
Katarina [22]

Answer: 545 words per 35 mins

Explanation:

4 0
3 years ago
Read 2 more answers
Write a regular expression pattern that matches strings representing trains. A single letter stands for each kind of car in a tr
MAVERICK [17]

Answer:

See explaination

Explanation:

import re

def isValidTrain(train):

pattern = r'^E+(((P|PP|PPP|PPPP)D)*(BB)*)*C$'

if re.match(pattern, train):

return True

return False

def checkAndPrintTrain(train):

print("Train", train, "is valid:", isValidTrain(train))

checkAndPrintTrain("EC")

checkAndPrintTrain("EEEPPDBBPDBBBBC")

checkAndPrintTrain("EEBB")

checkAndPrintTrain("EBBBC")

checkAndPrintTrain("EEPPPPPPDBBC")

checkAndPrintTrain("EEPPBBC")

checkAndPrintTrain("EEBBDC")

Sample output

Train EC is valid: True

Train EEEPPDBBPDBBBBC is valid: True

Train EEBB is valid: False

Train EBBBC is valid: False

Train EEPPPPPPDBBC is valid: False

Train EEPPBBC is valid: False

Train EEBBDC is valid: False

6 0
3 years ago
A,B, or C. pls help me out!!!!!!!!!!
schepotkina [342]

<span>Bitmap images are A. best suited for three-dimensional designs and graphics with color blends found in web pages. </span>

<span>
Taken for granted that Maria’s work is original work, Bitmap images are the best to use on a website. Bitmap is a format for photographs and graphics with a wide range of colours and effects (for example a button with a shadow), which creates realistic images.</span>

 

6 0
3 years ago
Other questions:
  • Qu'est-ce qui motive le choix d'une autre?
    7·1 answer
  • What does CSS stand for?
    8·2 answers
  • count multiples(num1, num2, AND) Description: Returns the number of multiples of N that exist between num1 and num2 inclusive. P
    12·1 answer
  • While traditionally employers used computers to track ordering and inventory, computers are used now to
    11·1 answer
  • Jesse wants to create a website with her company name as the address. What should she do next?
    9·1 answer
  • Answer is B because portrait is define that they take only photographs of people and like to communicate with people they are we
    10·1 answer
  • What is the largest software application on a computer?
    15·2 answers
  • Drag each tile to the correct box. (No links please)
    8·2 answers
  • A user asks for a checkbox to be automatically ticked if the annual revenue field is greater than a million. Which formula to tr
    5·1 answer
  • What is a leased line​
    12·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!