Hello, I have been messing around and writing more and more intricate calculator programs on MVE C++. The issue I am having right now is my program is not running unless I give my add, sub, etc. a value. When I try to just leave them as int add; or int sub; It will not do the equation. Also, if I try to have my couts of cout<<"Your sum...<<add will not appear unless in the do-while loop. Lastly, if I hit q or Q it causes the program to output alot of random things, even though I made my while statement. I thank everyone who helps in advance, and my main concerns are the cout<< not displaying after while and Q messing up the program.
#include <iostream>
#include <cmath>
using namespace std;
int main()
{
int value;
int sub=0;
int add=0;
int multp=1;
double avg=0;
int n=0;
cout<<"Input your values (Press Q to quit)"<<endl;
do
{
cout<<"Your sum is "<<add<<endl;
cout<<"Your diff is "<<sub<<endl;
cout<<"Your mult is "<<multp<<endl;
cout<<"Your avg is "<<avg<<endl;
cin>>value;
add+=value;
sub-=value;
multp*=value;
n++;
avg=(add/n);
}while(value!='q' && value!='Q');
return(0);
}