题解 | 一元二次方程
一元二次方程
https://www.nowcoder.com/practice/f1b20bcca3d847bea0afcbffef1d4e69
class Solution {
public:
/**
* 代码中的类名、方法名、参数名已经指定,请勿修改,直接返回方法规定的值即可
*
* 判断二元一次方程组是否有解
* @param a int整型 二次项系数
* @param b int整型 一次项系数
* @param c int整型 常数项
* @return bool布尔型
*/
bool judgeSolutions(int a, int b, int c) {
// write code here
return b*b-4*a*c>=0;
}
};
查看8道真题和解析