Help with exponents loop, not allowed to use pow() library

so i'm trying to set up this exponents loop, keep in mind this is my first year in computer science so my knowledge of script is somewhat minimal. basically this assignment (or at least part of it) tells us to have the user enter 2 numbers, (left and right) and to output the correct answer using a loop to calculate. my idea was to use to write a script so the number the user inputs for the right side will determine the number of times the loop runs. this is what i have so far but it's not working. can anyone help please?

#include <iostream>

using namespace std;

int main()
{
int left, right;

cout << "Enter left and right side: ";
cin >> left >> right;

for (right;;)

left *= right;


system("pause");
return 0;
}
[838 byte] By [zalery] at [2007-11-20 11:33:41]
# 1 Re: Help with exponents loop, not allowed to use pow() library
In the future, please use [ CODE ] [ /CODE ] tags to display your code.
This is not the way a for loop should be written.
See this link ( http://www.hitmill.com/programming/cpp/forLoop.htm) for a short tutorial on for loop syntax.
Zachm at 2007-11-9 1:25:50 >
# 2 Re: Help with exponents loop, not allowed to use pow() library
int result = 1;
for (; right--; )
result *= left;
NMTop40 at 2007-11-9 1:26:50 >
# 3 Re: Help with exponents loop, not allowed to use pow() library
int result = 1;
for (; right--; )
result *= left;

ahh thank you!!!
i've been looking all night and couldnt really get a straight answer!!
zalery at 2007-11-9 1:27:49 >