answer.
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
stich3
15 days ago
14

Write a program in pascal to find the area of a circle

Computers and Technology
1 answer:
Rzqust [894]15 days ago
5 0

Program Area_Circle;

Uses Crt;

Const

Pi = 3.1416;

Var

Radius: Integer;

Area: Real;

Begin

Clrscr;

Writeln('Area of a Circle Solver');

Writeln;

Write('Enter the Radius of the Circle: ');

Readln(Radius);

Area:= (Pi * Radius * Radius);

Writeln;

Writeln('The Area of the Circle is ',Area:8:2,'.');

Writeln;

Writeln('Program Executed');

Readln;

End.

I hope this helps!

You might be interested in
How can you check an orthographic drawing to be sure there are no missing lines
maria [879]
Using a magnifying glass.
4 0
21 day ago
c++ You are given an array A representing heights of students. All the students are asked to stand in rows. The students arrive
maria [879]

The following code will assist you in solving the specified problem; you can run it and verify against some sample input and output.

#include<stdio.h>

#include<string.h>

 int* uniqueValue(int input1,int input2[])

 {

   int left, current;

   static int arr[4] = {0};

   int i      = 0;

     for(i=0;i<input1;i++)

      {

         current = input2[i];

         left    = 0;

         if(current > 0)

         left    = arr[(current-1)];

      if(left == 0 && arr[current] == 0)

       {

       arr[current] = input1-current;

       }

       else

   {

       for(int j=(i+1);j<input1;j++)

       {

           if(arr[j] == 0)

           {

               left = arr[(j-1)];

               arr[j] = left - 1;

           }

       }

   }

}

return arr;

}

4 0
11 days ago
Complete the function definition to output the hours given minutes. Output for sample program: 3.5
Harlamova29_29 [932]

#include <iostream>

using namespace std;


void OutputMinutesAsHours(double origMinutes) {

double hours = origMinutes / 60.0;

cout << hours;

}


int main() {

OutputMinutesAsHours(210.0); // This function will also be called with 3600.0 and 0.0.

cout << endl;

return 0;

}


The lines highlighted in bold perform the conversion from minutes to hours by dividing the input minutes by 60, since there are 60 minutes in one hour. The parameter origMinutes is a double, so the division uses 60.0 to keep consistent data types. Running this code with 210.0 will output 3.5.

4 0
1 month ago
Assume there is a machine with the IP address 129.82.102.63 with netmask /23, and with a parent NW whose netmask is 255.255.224.
8_murik_8 [892]
The complete query is as follows: Assume there exists a machine with the IP address 129.82.102.63 with a netmask of /23, and a parent network (NW) with a netmask of 255.255.224.0. For all answers, refrain from adding spaces, provide full IP addresses/netmasks as requested, and include the "/" in the slash notation.
3 0
18 days ago
#Write a function called "replace_all" that accepts three #arguments: # # - target_string, a string in which to search. # - find
oksian1 [797]

Answer:

Here is the function called replace_all:

def replace_all(target_string,find_string,replace_string):

   result_string = replace_string.join(target_string.split(find_string))  

   return result_string

#To see how this function operates, you can invoke it using the following code:

target_string = "In case I don't see ya, good afternoon, good evening, and good night!"

find_string = "good"

replace_string = "bad"

print(replace_all(target_string, find_string, replace_string)

Explanation:

The aforementioned program contains a function named replace_all that accepts three parameters: target_string, which is the string to search within; find_string, which is the string you are searching for; and replace_string, which is the string utilized to replace all occurrences of find_string. The function executes the following statement:

replace_string.join(target_string.split(find_string))  

The split() method in this context divides target_string into a list according to find_string. Here, find_string is provided to the split() method as a parameter, acting as a separator. For example:

target_string = In case I don't see ya, good afternoon, good evening, and good night!

find_string = good

After executing target_string.split(find_string), we obtain:

["In case I don't see ya, ", ' afternoon, ', ' evening, and ', ' night']

The join() method then concatenates the elements of the list generated by target_string.split(find_string). Here, join takes that list as a parameter and connects its elements using 'bad'.

The resulting replace_string = badSubsequently, after using replace_string.join(target_string.split(find_string)), we generate:

In case I don't see ya, bad afternoon, bad evening, and bad night!

The code and output are attached as a screenshot.

7 0
13 days ago
Other questions:
  • Which of these is an example of the integrity principle that can ensure your data is accurate and untampered with?
    10·2 answers
  •  How does critically analyzing technology add value to interactions with people in personal and professional contexts?
    9·2 answers
  • python Consider this data sequence: "3 11 5 5 5 2 4 6 6 7 3 -8". Any value that is the same as the immediately preceding value i
    7·1 answer
  • How concerned are you about the security of rtos in cars smart homes and wearable technology?
    15·1 answer
  • Assume that getPlayer2Move works as specified, regardless of what you wrote in part (a) . You must use getPlayer1Move and getPla
    14·1 answer
  • When performing actions between your computer and one that is infected with a virus which of the following offers no risk becomi
    5·1 answer
  • Which of the following is true? a. Pseudocode is used to describe an algorithm. b. Pseudocode is not an actual computer programm
    11·1 answer
  • The table is an excerpt from an interviewer’s notes about three applicants applying to the IT department.                
    15·1 answer
  • Factoring of integers. Write a python program that asks the user for an integer and then prints out all its factors. For example
    13·1 answer
  • Tanya wants to include a video with all its controls on her web page. The dimensions of the video are as follows:
    6·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!