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
Agata [3.3K]
3 years ago
9

Write the program to solve quadratic equations, but if the discriminant is negative, output

Computers and Technology
1 answer:
Firdavs [7]3 years ago
8 0

Answer:

PROGRAM  QuadraticEquation Solver

  IMPLICIT  NONE

REAL :: a, b, c ;

  REA :: d ;

  REAL  :: root1, root2 ;

//read in the coefficients a, b and c

  READ(*,*)    a, b, c  

  WRITE(*,*)   'a = ', a

  WRITE(*,*)   'b = ', b

  WRITE(*,*)    'c = ', c

  WRITE(*,*)

// computing the square root of discriminant d

  d = b*b - 4.0*a*c

  IF (d >= 0.0) THEN              //checking if it is solvable?

     d     = SQRT(d)

     root1 = (-b + d)/(2.0*a)     // first root

     root2 = (-b - d)/(2.0*a)     // second root

     WRITE(*,*)  'Roots are ', root1, ' and ', root2

  ELSE                            //complex roots

     WRITE(*,*)  'There is no real roots!'

     WRITE(*,*)  'Discriminant = ', d

  END IF

END PROGRAM  QuadraticEquationSolver

You might be interested in
How does this happen on brainly????
Trava [24]

what do you mean????

4 0
3 years ago
Read 2 more answers
Which are characteristics of interpreters? Select
SVEN [57.7K]

Answer:

translation is used for interpretation

8 0
3 years ago
Read 2 more answers
15. How many PC’s can be connected to a UPS?
Alex_Xolod [135]

Answer: Depends on the power of the computer /computers and the UPS

Explanation: For someone who had a big connected network of computers and printers we would plug the computer or server into the UPS as well as the monitor and sometimes a printer sometimes the monitor was plugged into the wall

When you get a UPS you must plug it in for a certain time could be hours or even a day.  A USP has a big battery in it and you must charge it (sometimes it comes semi-charged but you must plug it in to strengthen it. )

there are two connector wires that you affix to the battery and you must put a lot of strength into it to make it secure.

So in closing, you can get away with two like a desktop and a laptop.

Read your documentation that comes with the UPS

6 0
1 year ago
Please help guys I'm so lost ​
PilotLPTM [1.2K]

Answer:

The correct answer is C ( W * 5 )

4 0
3 years ago
Read 2 more answers
The _____, also known as the system chassis, is a container that houses most of the electronic components that make up a compute
vodka [1.7K]

Answer:

I am pretty sure it is the RSA

Explanation:

7 0
2 years ago
Other questions:
  • Does group policy management matter without a server environment?
    7·1 answer
  • Which of the following is a category of social media?
    8·2 answers
  • Jane sold many notebooks at her school fair and earned a good amount of cash. To keep a record, she entered all the cash values
    10·1 answer
  • Ssume the following variables contain the values shown: numberRed = 100 numberBlue = 200 numberGreen = 300 wordRed = "Wagon" wor
    5·1 answer
  • Write a program roman which converts numbers from decimal notation into Roman numerals. roman takes a single argument, a string
    10·1 answer
  • Set screw compression and indenter are all types of
    13·2 answers
  • Which program will have the output shown below?
    7·1 answer
  • What is the organizational management practices on planning during a pandemic like corona virus.
    5·1 answer
  • If you can photoshop please text me i need help for my digital media class 7862381441
    9·1 answer
  • Add comma(s) where needed, if needed.
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!