Dyskusje Q&A
Podrían ayudarme con esto??
0 głosów
1 OdpowiedźExplain it...
0 głosów
2 odpowiedziPi calculation on Java
-2 głosów
1 Odpowiedźc++
0 głosów
1 Odpowiedź"Char" and "Double"
2 głosów
1 Odpowiedźc++ float vs java float
2 głosów
2 odpowiedziJava
0 głosów
4 odpowiedziWhy Error?
0 głosów
1 OdpowiedźDistance - c#
0 głosów
3 odpowiedziPrime number
2 głosów
3 odpowiedziWrite and test a program that solves quadratic equations. A
quadratic equation is an equation of the form ax2+ bx + c =0 ,where a,b and c are given coefficient and x is the unknown The coefficients are real number inputs ,so they should be declared of type float or double Since quadratic equations typically have two solutions ,use x1 and x2 for the solutions to be output These should be declared of type double to avoid inaccuracies from round-off error
-1 Głos
3 odpowiedzi#include <iostream>
using namespace std;
class employee
int main()
{
private:
double salary;
public:
void getsalary(double sal)
{
salary=sal;
}
void display()
{
cout<<"the salary:"<<salary;
}
};
void main ()
{
employee programmer;
employee manager;
manager.getsalary (60000.0);
programmer.getsalary(40000.0);
manager.display();
programmer.display();
return 0;
}
1 Głos
5 odpowiedziString
0 głosów
2 odpowiedziPopularne dzisiaj
Python
1 Votes
Are websites hackable?
1 Votes
TICTACTOE
0 Votes
Error
0 Votes
Learn python
0 Votes
Help for study
0 Votes
BIG DOUBT🤔🤔🤔🤔
1 Votes
Need help (French)
0 Votes
What's an unsigned int?
0 Votes