-
April 26th, 2014, 06:00 AM
#16
Re: Wombat 1
Originally Posted by rockx
Yeah the comment should have read line 40. I did some line deletions so i reduced my program from 52 lines to 42 lines. At line 40, the constant 10 is stored.
That particular code was for a an instruction set as follows:
1. User enters an integer n
2. If n < 0 then n^5 (n x n x n x n x n); if n = 0 then 10; if n > 0 then n^2 - 2n +2
3. THere was no looping, it was just a single run program.
As the program produces the expected answers, I think the program in post #13 is now working as far as has been tested.
All advice is offered in good faith only. All my code is tested (unless stated explicitly otherwise) with the latest version of Microsoft Visual Studio (using the supported features of the latest standard) and is offered as examples only - not as production quality. I cannot offer advice regarding any other c/c++ compiler/IDE or incompatibilities with VS. You are ultimately responsible for the effects of your programs and the integrity of the machines they run on. Anything I post, code snippets, advice, etc is licensed as Public Domain https://creativecommons.org/publicdomain/zero/1.0/ and can be used without reference or acknowledgement. Also note that I only provide advice and guidance via the forums - and not via private messages!
C++23 Compiler: Microsoft VS2022 (17.6.5)
-
April 26th, 2014, 03:08 PM
#17
Re: [RESOLVED] Wombat 1
Can this thread be deleted?
-
April 26th, 2014, 03:27 PM
#18
Re: [RESOLVED] Wombat 1
Originally Posted by KChad
Can this thread be deleted?
Why? Threads are left on the forum for future reference.
All advice is offered in good faith only. All my code is tested (unless stated explicitly otherwise) with the latest version of Microsoft Visual Studio (using the supported features of the latest standard) and is offered as examples only - not as production quality. I cannot offer advice regarding any other c/c++ compiler/IDE or incompatibilities with VS. You are ultimately responsible for the effects of your programs and the integrity of the machines they run on. Anything I post, code snippets, advice, etc is licensed as Public Domain https://creativecommons.org/publicdomain/zero/1.0/ and can be used without reference or acknowledgement. Also note that I only provide advice and guidance via the forums - and not via private messages!
C++23 Compiler: Microsoft VS2022 (17.6.5)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|