Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //math.cpp
- //Creative Commons copyright (c) Lauri Friberg 2010, 2014, 2018
- //Converted from C to C++ on 15.9.2018 at 16:23 hours, (2018/9/15, September the 15th of 2018 at 4:23 PM).
- //#include <stdio.h>
- #include <iostream>
- using namespace std;
- int main() {
- float a, b, c, x, y;
- cout << "a="; cin >> a;
- cout << "b="; cin >> b;
- cout << "c="; cin >> c;
- cout << "x="; cin >> x;
- y = a*x*x+b*x+c;
- cout << "y=ax²+bx+c=" << y << "\n";
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment