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
(I WILL GIVE BRAINLIEST) Which steps will delete an appointment?
Nastasia [14]

Answer:

right clicking should be your answer

3 0
3 years ago
A user clicked an email link that led to a website than infected the workstation with a virus. The virus encrypted all the netwo
Leno4ka [110]

Answer:

D

Explanation:

A zero-day vulnerability is a computer-software vulnerability that is unknown to those who would be interested in mitigating the vulnerability. Until the vulnerability is mitigated, hackers can exploit it to adversely affect computer programs, data, additional computers or a network. An exploit directed at a zero-day vulnerability is called a zero-day exploit, or zero-day attack.

5 0
3 years ago
If a website ends with .gov does it mean that its written by the government or?
Soloha48 [4]
Umm... No. (I'm pretty sure)
7 0
3 years ago
Read 2 more answers
Explain how AI smartphone software in the rental car can be a threat to privacy.
Elan Coil [88]

Answer:

The real reason why AI smartphone software in the rental car is threat to privacy is that the data transmitted can actually be exposed to security breaches in the software and so if that happens, the car is no longer under the control of the user.

Hope this helps!

4 0
2 years ago
Convert the following binary to decimal number . <br>a). 101101 ​
KonstantinChe [14]
First things first you have to do write it down which you did
step 2: then you multiply each digit of the binary number by the corresponding power of 2: 1x25 + 0x24 + 1x23 + 1x22 + 0x21 + 1x2 0
step 3: solve the powers: 1x32 + 0x16 + 1x8 + 1x4 + 0x2 + 1x1 = 32 + 0 + 8 + 4 + 0 + 1
step 4: add the numbers written above

32 + 0 + 8 + 4 + 0 + 1 = 45.
So, 45 is the decimal equivalent of the binary number 101101.
5 0
2 years ago
Read 2 more answers
Other questions:
  • Which sparkline type is best for displaying trends in data changes over time?
    11·1 answer
  • when reading a recipe ingredients witch substance make the rice an unhealthy choice if it is present in a high amount
    13·1 answer
  • Questions 1 )When does a spring tide take place?
    14·2 answers
  • 0.005098 megaliters to liters. Show your work.
    11·1 answer
  • True or False <br><br> The term virus and malware may be used interchangeably.
    13·1 answer
  • Please help Ill give you brainliest if I get 2 answers. Which is used to input information on a laptop?
    6·1 answer
  • Good ways to increase sales on phone accesories?
    10·2 answers
  • Need Help Please
    7·1 answer
  • please help me to do this computer homework I beg you all please help me to get the answers please its important please ​
    12·1 answer
  • sing the drop-down menu, identify the flowchart symbols. The oval represents the . The rectangle represents the . The diamond re
    9·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!