0

So i wanted to build a program in which scientific sums are solved along with the steps .I tried but i failed .

Here is the code ~

```
#include <iostream>
#include <cstdlib>
#include <windows.h>
#include <conio.h>
using namespace std;
int main(){
int reply;
int u ,v ,t;
int a = v-u/t;
cout << "1.Press 1 to find out acceleration" << endl;
cout << "2.Press 2 to find out velocity time relation"<< endl;
cout << "3.Press 3 to find out postive time relation" << endl;
cout << "4.Press 4 to find out positive velocity relation" << endl;
cin >> reply;
if (reply==1){
cout <<"enter your initial velocity(u)" << endl;
cin >> u;
cout << "enter your final velocity(v)" << endl;
cin >> v;
cout << "enter your time(t)" << endl;
cin >> t;
cout << "The formula is - a=v-u/t " << endl;
cout << "Therefore " << "a=" << v << "-" << u << "/" << t << endl;
cout << "=" << "a=" << v-u << "/" << t << endl;
cout <<"=" << a << endl;
}
system("pause");
}
```

Its incomplete ,but even the first code to find out the acceleration is not working .

For eg ~ When i enter the intial velocity as 20 and final velocity as 20 and time as 10 it shows up correctly up to " 0/10 "

But when printing the final result that is "v-u/t" it fails terribly .

A long number like "20001002" something comes up .

I am still a beginner but would like to know how to fix this issue .

Help would be greatly appreciated .