Pardon the "n00b" question, but if there's a sqrt() function in <math> then why the heck doesn't
give me i squared? (I know, ^ is some kind of logical operator.)Code:std::cout<<i^2;
Where are the dang exponents?
I've googled and searched the site but I'm sure you guys can answer this in far less time that it will take me to flounder around.Code:#include <iostream> int main () { int i = 1; while (i <= 10) { std::cout<<i*i<<std::endl; ++i; } system("PAUSE"); return 0; }
Thanks!
-JM