id/email
password
forgot password | create account
about | help | code help+videos | done | prefs
CodingBat code practice

 

frew@mclean.com unit3virtualday1 > discriminant
prev  |  next  |  chance

Return the discriminant of the quadratic. The formula is: b^2 - 4ac


discriminant(1, 6, 5) → 16.0
discriminant(1, 6, 9) → 0.0
discriminant(4, -2, 5) → -76.0

...Save, Compile, Run (ctrl-enter)

public double discriminant(double a, double b, double c) { }

Editor font size %:
Shorter output


Forget It! -- delete my code for this problem

Progress graphs:
 Your progress graph for this problem
 Random user progress graph for this problem
 Random Epic Progress Graph

Java Help

Misc Code Practice

Difficulty: 100

Copyright Nick Parlante 2017 - privacy