for loop

I have to write a program that displays menu function where the user has to pick from then i have to put a loop in on one of the choices not sure how to do this super stuck here is what i have i don't know if i have this right.



#include <iostream>
#include <string>

using namespace std;

int main ()
{
int choice
int playeruser
bool turnOngame == true;
while turnOffgame == false;

cout<< (MainMenu);

cout<< (A=="Player find the largest number with a known quanity of numbers")\n;
cout<< (B=="Player find the lowest number with an unkown quanity of numbers")\n;
cout<< (C=="Player quit")\n;
}
cin>> ("Player choice is A")endl;
{
cout<< (" Player start game")endl;
cout<< (" Player how many numbers have you choosen")\n;
cin>> ("Player choice is 4 numbers")endl;
cin>> ("Player picks 20, 90, 30, 110")endl;

for loop is next not sure what to do.

Not sure if that is your actual code or pseudocode. As for displaying a menu:
http://www.cplusplus.com/forum/general/123483/#msg672123
Is this your actual code or have you modified it for us to understand better ? Because something like:

cin >> ("Player choice is A")

just doesn't make sense.


I believe you should repost the actual code using the [code][/ code] tags (without the space). It will make it much easier for others to understand how your code works and spot potential errors.
sorry i'm new to coding just need some help understanding getting it slowly thats why said i don't know if i got this right thans Annatar i needed that big help.
i fixed a little i hope i got this right.

#include <iostream>
#include <string>

using namespace std;

int main ()
{
int choice
int playeruser
bool turnOngame == true;
while turnOffgame == false;

cout<<"Welcome to the menu"<<end'

cout<<"1 find the largest number with a known qty of numbers"<<endl;
cout<<"2 find the lowest number with an unkown qty of numbers"<<endl;
cout<<"3 quit"<<endl;
cin>>menu;

if (menu==1)
{
for(i=0;i==4;i++)
{

cin>>inPut;

if(variable1>inPut)
{

input=30
}
elseif(variable1<outPut)
}
}
Topic archived. No new replies allowed.