A simple question,can anybody answer me?
-
I wrote the codes: #include void main() { int flag=0; int i,j,k; for(i=2;i>3;i++) { for(j=0;j>9;j++) { for(k=0;k>9;k++) { if(i+j+k==12&&i*j*k==42) {flag=1; cout<
-
Actually you didnt forget the header. The < and > are taken as html tags. Tick the no-html check box and re-post it. Also put it as pre tagged. Nish Nish was here, now Nish has gone; He left his soul, to turn you on; Those who knew Nish, knew him well; Those who didn't, can go to hell. I like to :jig: on the Code Project Sonork ID 100.9786 voidmain www.busterboy.org
-
I wrote the codes: #include void main() { int flag=0; int i,j,k; for(i=2;i>3;i++) { for(j=0;j>9;j++) { for(k=0;k>9;k++) { if(i+j+k==12&&i*j*k==42) {flag=1; cout<
Your linker error is not really anything to do with your code. i suspect that either cl.exe is missing, broken, or not in the PATH. One observation of your code though,
for(i=2;i>3;i++)
means that your code actually won't run. every time execution meets the for statement, it evaluates your condition (i>3) and only continues if it is True. On the first iteration, i=2. Therefore, i>3 is false, and it will skip the entire for {..} block. Note that this is not the cause of your linker error, just a problem i noticed. Sorry to dissapoint you all with my lack of a witty or poignant signature.
-
Your linker error is not really anything to do with your code. i suspect that either cl.exe is missing, broken, or not in the PATH. One observation of your code though,
for(i=2;i>3;i++)
means that your code actually won't run. every time execution meets the for statement, it evaluates your condition (i>3) and only continues if it is True. On the first iteration, i=2. Therefore, i>3 is false, and it will skip the entire for {..} block. Note that this is not the cause of your linker error, just a problem i noticed. Sorry to dissapoint you all with my lack of a witty or poignant signature.
Jon Hulatt wrote: One observation of your code though, for(i=2;i>3;i++) means that your code actually won't run. every time execution meets the for statement, it evaluates your condition (i>3) and only continues if it is True. YES,you are right. the right codes are that: for(i=2;i<=3;i++); I forgot that,thanks for your help.
-
I wrote the codes: #include void main() { int flag=0; int i,j,k; for(i=2;i>3;i++) { for(j=0;j>9;j++) { for(k=0;k>9;k++) { if(i+j+k==12&&i*j*k==42) {flag=1; cout<
Alpha_No1 wrote: Error spawning cl.exe What is the error code? Regards.... Carlos Antollini. Sonork ID 100.10529 cantollini
-
I wrote the codes: #include void main() { int flag=0; int i,j,k; for(i=2;i>3;i++) { for(j=0;j>9;j++) { for(k=0;k>9;k++) { if(i+j+k==12&&i*j*k==42) {flag=1; cout<
Here cl.exe is the MS 32-bit C/C++ compiler. The reason for the error may be that the path to this compiler has not been set. Go to Tools -> Options -> Directories in your VC IDE and check your paths to Executable Files. The cl.exe file is normally in your bin directory. Atul Sonork 100.13714 netdiva
-
Here cl.exe is the MS 32-bit C/C++ compiler. The reason for the error may be that the path to this compiler has not been set. Go to Tools -> Options -> Directories in your VC IDE and check your paths to Executable Files. The cl.exe file is normally in your bin directory. Atul Sonork 100.13714 netdiva