| | |
I really need help,please
Please support our Java advertiser: Programming Forums - DaniWeb Sister Site
![]() |
•
•
Join Date: Nov 2009
Posts: 4
Reputation:
Solved Threads: 0
heey all ,,
I'v a question about the pow ,, but when I run the programe it didn't work =S
I really need help because tomorrow I shloud give it to my teacher,,
********************************************
import java.lang.Math;
public class ques3
{
public static void main(String[]args)
{
static Scanner console = new Scanner(System.in);
float a,b,c;
System.out.println("Enter a ");
a=console.nextFloat();
System.out.println("Enter b ");
b=console.nextFloat();
System.out.println("Enter c ");
c=console.nextFloat();
sum=Math.Pow((double)b*b-4*a*c,0.5);
I'v a question about the pow ,, but when I run the programe it didn't work =S
I really need help because tomorrow I shloud give it to my teacher,,
********************************************
import java.lang.Math;
public class ques3
{
public static void main(String[]args)
{
static Scanner console = new Scanner(System.in);
float a,b,c;
System.out.println("Enter a ");
a=console.nextFloat();
System.out.println("Enter b ");
b=console.nextFloat();
System.out.println("Enter c ");
c=console.nextFloat();
sum=Math.Pow((double)b*b-4*a*c,0.5);
•
•
Join Date: Nov 2009
Posts: 4
Reputation:
Solved Threads: 0
0
#3 33 Days Ago
3. Write expressions to compute both solutions for the quadratic formula. The formula is (b^2-4ac)^0.5
The symbol means “plus or minus” and indicates that the equation has two solutions: one in which the result of the square root is added to -b and one in which the result is subtracted from -b. Assume all variables are float variables.
this it the question ,,
The symbol means “plus or minus” and indicates that the equation has two solutions: one in which the result of the square root is added to -b and one in which the result is subtracted from -b. Assume all variables are float variables.
this it the question ,,
•
•
Join Date: Nov 2009
Posts: 4
Reputation:
Solved Threads: 0
0
#7 33 Days Ago
ok I correct it ,,
but just one more question ,,
in the statment :
how can I say before this statment ?
sum=console.nextdouble ?!
or what ?!
sorry but I'm not a perfect in java
but just one more question ,,
in the statment :
Java Syntax (Toggle Plain Text)
System.out.println("the value="+sum);
how can I say before this statment ?
sum=console.nextdouble ?!
or what ?!
sorry but I'm not a perfect in java
![]() |
Other Threads in the Java Forum
- Previous Thread: Incompatible types found (HELP!)
- Next Thread: How to implement a sample saas application
| Thread Tools | Search this Thread |
actuate android api applet application applications array arrays automation balls bank binary bluetooth business chat class classes clear client code codesnippet collections component database db defaultmethod development dice dragging draw ebook eclipse error event exception formatingtextintooltipjava fractal game givemetehcodez graphics gui html ide image infinite input integer invokingapacheantprogrammatically j2me java javaprojects jni jpanel julia linux list loop looping map method methods mobile mysql netbeans newbie numbers openjavafx oracle parameter php print problem program programming project recursion repositories scanner screen scrollbar server set size sms sort sorting sql sqlserver state storm string sun superclass swing swt text-file threads time tree windows






