الفريق العربي للبرمجةأرشيف المنتديات · 2000 – 2023
نسخة أرشيفية للقراءة فقط — التسجيل والمشاركة مغلقان، والمحتوى محفوظ كما كان.

أرجوكم أحد يحل لي هدي السول

بدأه mansour91b في 16 سبتمبر 2008 · 4 رد · 647 مشاهدة · في JavaSE
مشاركة: واتساب X فيسبوك تيليجرام
#1 صاحب الموضوع

السلام عليكم

أهلا بي الجميع

المهم هدي السول حولت فيه لكن معرفتش الناتج

أرجو من ألي يعرف الجوب يكتبه

هدي السول

Solving Quadratic equations.

The standard form of a quadratic formula is as follows:

ax2 +bx +c = 0

In order to solve it, the formula is:

Your program will populate the values of a, b, and c.

Your program will display the two answers: using plus, then the minus before the square root sign. Your answer should be rounded to 2 decimal places.

Use variables that will allow your equation to be broken up into smaller chunks in a way that can add clarity.

وشكرا

#2

أخي السؤال أبسط من ان يجاوب عليه

حاول انت تعمل اي شئ في هذا السؤال وضعه

في المنتدى و عندها يمكننا مساعدتك بإكمال الشئ الناقص به

#3

أنا حولت فيه هدي

package javaapplication2;

public class NewMain {

public static void main(String[] args) {

double a, b, c, formola;

a = 5;

b = 8;

c = 6;

formola = (-b - (b * B) - (4 * a * c) / 2 * a);

System.out.println("the anser is" + formola);

}

}

#4
public class NewMain {

	public static void main(String[] args) {
		double a, b, c, delta, x1, x2, x;
		a = 4;
		b = 10;
		c = 6;
		delta = b*b - 4 * a * c;
		if (delta > 0)
		{
			   x1 = (-b - Math.sqrt(delta)) / (2 * a);
			   x2 = (-b + Math.sqrt(delta)) / (2 * a);
			   System.out.println ("x1 = " + Math.rint(x1 * 100.0d)/100.0d);
			   System.out.println ("x2 = " + Math.rint(x2 * 100.0d)/100.0d);
		} else if (delta == 0) {
			   x = -b/2*a;
			   System.out.println ("x = " + Math.rint(x * 100.0d)/100.0d);
		} else { System.out.println ("no solution"); }
	}
}

أساسيات الرياضيات يا أخي والمرجع موجود:

Google

Do as I say, not as I do

We are Anonymous. We are Legion. We don't forgive. We don't forget

#5

مشكووووووووووووووووووووووووووور جدا يا أخ xacker

مواضيع مشابهة