ГлавнаяСборникиТурнирыРазделыФорумыУчастникиПечатьПомощьО системе

Сборники > Beginners > задача:


068. 50581 - Rrenjet e Ekuacionit Kuadratik

Гость
• Обсуждение задачи (1)

Задачи сборника

• 034. 50502 - Welcome Andi - 1
• 042. 50798 - Passing the course
• 045. 50391 - Cinema Tickets
• 048. 50403 - Number of Chairs
• 052. 50503 - Welcome Andi - 2
• 053. 50501 - The Highest Average
• 062. 50402 - Hello World!
• 063. Cifti me i afert
• 068. 50581 - Rrenjet e Ekuacion...
• 100. 50532 - Close City
• 120. 50511 - Class Average
• 130. 50416 - Placing Dominoes on ...
• 140. 50417 - Fun Fair
• 150. 50500 - Find Student
• 260. 50460 - Numrin e Mesem
• 50292 - Average of 4 Marks
• 001. 51153 - A+B

Обратная связь

Если у вас есть предложения или пожелания по работе Contester, посетите форум сайта www.contester.ru.

Лимит времени 2000/4000/4000/4000 мс. Лимит памяти 65000/65000/65000/65000 Кб.
Question by Ibrahim Mesecan.

The roots of a quadratic equation

Shqip

Question: In elementary algebra, quadratic expressions are represented in the form


Then, its discriminant is calculated using the following formula

According to the value of discriminant, there are three cases:

  1. If the discriminant is zero, then, there is one real root.
  2. If the discriminant is positive, then, there are two distinct real roots.
  3. If the discriminant is negative, then, there are no real roots.
Write a program that gets three integers and then, calculates and shows the roots.

Input specification
You will be given three integers which are between -1000 and 1000.

Output specification

  • If there is no real root show the message "No real root".
  • If there is one real root, show it with two digits precision.
  • If there are two roots, show them with 2 digits precision in the order given above.

 Sample Input I     Sample Input II   
 1 2 1
 2 3 4
 Sample Output I     Sample Output II   
 -1
 No real root


Для отправки решений необходимо выполнить вход.

www.contester.ru