-
Created Inexplicable error
Hello, I feel like this is probably something silly, but for some reason if I declare a variable at a certain point in my code, then never use it... it … -
Marked Solved Status for Generic streams
Hello, Looking at the standard streams provided by the stl libraries, it seems as though it is impossible to have 1 stream to use for both standard console IO and … -
Replied To a Post in Generic streams
I suppose you are right. Combined I/O is too difficult to standardize. I am going to have to change my definitons so that I don't require it. This program is … -
Replied To a Post in Generic streams
Thanks, a great reply as usual. I just don't understand why we can't do read and write to the standard console. Every OS seems to have some way to do … -
Created Generic streams
Hello, Looking at the standard streams provided by the stl libraries, it seems as though it is impossible to have 1 stream to use for both standard console IO and … -
Marked Solved Status for Windows API GetPixel returning -1
Hello, I have a `HWND` for a window. I have double checked that it is a 100% valid window by using `SetActiveWindow()`, `SetFocus()`, and `SetForegroundWindow()` on it, successfully bringing it … -
Replied To a Post in Windows API GetPixel returning -1
Sorry about the late post, it took me forever to test your code with my modifications due to a few sneaky bugs (a dropped compiler and missing breaks were the … -
Replied To a Post in Windows API GetPixel returning -1
It occurs to me that the only reason I am using threads instead of a sequential programming is that I was under the impression that that was the only way … -
Replied To a Post in Windows API GetPixel returning -1
I checked against all of those conditions and here is what I found: 1. I am not sure how to check the clipping area, but my window is definitely larger … -
Created Windows API GetPixel returning -1
Hello, I have a `HWND` for a window. I have double checked that it is a 100% valid window by using `SetActiveWindow()`, `SetFocus()`, and `SetForegroundWindow()` on it, successfully bringing it … -
Marked Solved Status for Reading and Checking Unusual Characters
Hello, I have a file which I need to read which contains some unusual characters (EG: '╠') and I need to be able to read it and convert those characters … -
Replied To a Post in Reading and Checking Unusual Characters
Exactly what I was looking for. Thank you. -
Replied To a Post in Reading and Checking Unusual Characters
Is there any tutorial, or information webpage, somewhere that would explain how to use wchar_t's and wfstream's? Do they act like normal char's and fstream's? How to I specify unicode … -
Replied To a Post in Reading and Checking Unusual Characters
@NathanOliver yes, I know that ╠ happens to be expressible by ASCII 204, but some of my other symbols (like ₆ for example) are not expressible in ASCII, but rather … -
Created Reading and Checking Unusual Characters
Hello, I have a file which I need to read which contains some unusual characters (EG: '╠') and I need to be able to read it and convert those characters … -
Replied To a Post in How is the weather today in your country?
Heavy rain followed by negative temperatures = black ice... black ice everywhere :O. (Waterloo, ON... I think Toronto, ON too) -
Replied To a Post in What is your favorite English word?
I find that "Quinary son of a genetic algorithm" rolls of the tongue quite nicely when I want to let off some steam. As for a single word... Queueing's vowels … -
Marked Solved Status for Fast Integer Division
Hello, I wrote a library for arbitrary precision arithmetic recently and spent a long time implementing efficient multiplication algorithms. Now I am looking to see if it is possible for … -
Replied To a Post in Fast Integer Division
Excellent response as usual! Of course I have implemented the logical functions, as well as optimized them as far as I possibly could. I was sort of hoping that the … -
Replied To a Post in Fast Integer Division
Yeah, sorry about that. I actually have the class wrapped in a namespace so that ambiguity is avoided. Does that count as a valid naming convention? (IE: `LAB::Int`) -
Replied To a Post in Fast Integer Division
These are arbitrary-precision integer datatypes, sorry if I didn't make that clear. IE: Not `int` but `Int` which is a class that stores integers in an array of smaller integers. -
Replied To a Post in String analyzer
There are a few issues with your code, however the one causing the issue is a simple OBOE (off-by-one-error). The number one thing that jumps out at me is that … -
Created Fast Integer Division
Hello, I wrote a library for arbitrary precision arithmetic recently and spent a long time implementing efficient multiplication algorithms. Now I am looking to see if it is possible for … -
Replied To a Post in Having a little trouble
You have 1 syntax problem and a few redundancy problems. First lets tackle the syntax problem so that you can get your code to run. The syntax error is that … -
Replied To a Post in Having a little trouble
You have 1 syntax problem and a few redundancy problems. First lets tackle the syntax problem so that you can get your code to run. The syntax error is that … -
Marked Solved Status for Question concerning cast operator overloading.
Hello, I have a particular set up of cast operators and constructors which is leading to a compile-time ambiguity error. I am wondering if somebody can explain why this is … -
Replied To a Post in linking file with mutual dependencies
I am not 100% sure what you are asking since I can't access the code. However I think I understand what you are asking. You have two classes that refer … -
Replied To a Post in Question concerning cast operator overloading.
Ah, perfect. Thank you. :) -
Replied To a Post in Question concerning cast operator overloading.
Thanks for the clarification, but what really has me confused is that I can't seem to force explicit conversion either. It makes sense why `a=b` would be ambiguous, because it … -
Created Question concerning cast operator overloading.
Hello, I have a particular set up of cast operators and constructors which is leading to a compile-time ambiguity error. I am wondering if somebody can explain why this is … -
Replied To a Post in Hot Drink Menu
The issue is that you set `charges=number*PRICE_CONSTANT` each time, without saving the old value. Basically here is what happens if you trace charges (program tracing is a very valuable debugging … -
Replied To a Post in string pointer Array problem
Check your types, noting that `char x[]` is identical to `char *x`. So you can think of `char *colors[3][10]` as being the same as `char ***colors` or `char colors[][3][10]` either … -
Replied To a Post in Advice for creating my first game
For learning GameMaker there are these tutorials: http://sandbox.yoyogames.com/make/tutorials (Note: I haven't actually checked them out, so I am not sure if they are any good) For learning C++ console applications … -
Replied To a Post in Advice for creating my first game
Making games is difficult. I would put off making your current idea for a game until later and here is why. Ideas are cheap in the game industry. If you … -
Replied To a Post in about the pointer class(this)
I am not certain due to the ambiguity in your post, but I think you want to know how to do a deep copy. That is, how to copy pointer … -
Replied To a Post in Executable File Encrypt
The solution will depend on your specifications, you are being very vague about how you want to encrypt it. If all you want to do is make it hard for … -
Replied To a Post in Array name as Pointer variable.
I am not sure exactly what you mean by #2, but I can tell you about #1. The difference is that, as far as I know, you cannot create an … -
Replied To a Post in i m confused
Step 1: Install Compiler/IDE (I like to use Code::Blocks/G++) Step 2: Write program (You can learn C++ from many sites, I taught myself using learncpp.com) Step 3: Compile program (I … -
Replied To a Post in inline function
Basically, when a function is called in assembly language (which is what your C++ code gets turned into by the compiler) it actually takes real time to set up the … -
Replied To a Post in Joining to chars in c++
The issue is that char is an integer type, so `a+b` will add the ASCII values of a and b, which gives weird output. Converting them to strings works fine, … -
Marked Solved Status for Numbers in identifiers?
Hello, I have a quick question about c/c++ syntax. Basically I am wondering when it is allowable to have numbers in identifiers. My compiler happens to allow numbers in: * … -
Replied To a Post in Numbers in identifiers?
Thank you very much. -
Created Numbers in identifiers?
Hello, I have a quick question about c/c++ syntax. Basically I am wondering when it is allowable to have numbers in identifiers. My compiler happens to allow numbers in: * … -
Created Question concerning Taylor Polynomial approximations
Hello, I have used taylor polynomials to approximate floating-point values before. I am wondering whether there is a way to still apply them to functions with complex arguments, and if … -
Replied To a Post in Help with filling a structure from a file
The issue is that inFile isn't global, so every single function gets its own brand new version of inFile. The result is that you open it, then close it, then … -
Replied To a Post in Please help C++ program!!!
You should initialize it to MAX_ITERATIONS, just in case you never get a term less than 0.00001. -
Replied To a Post in Please help C++ program!!!
`cout<<"There were "<<numIterations<<" terms used in the series approximation."<<endl;` The whole point of saving i to numIterations is because outside the for loop 'i' doesn't exist, so its value (if … -
Replied To a Post in Please help C++ program!!!
Can you upload your new code so I can see where the issue is? -
Replied To a Post in Please help C++ program!!!
Your problem is that when you check that each term is >.0001 you check it against x. Your term is not x, its `pow(x,2*i)/factorial(2*i)` so you just need to modify … -
Marked Solved Status for OpenGL Render to Image
Hello, I can get OpenGL to render 3D scenes to the screen, but I want to render them to a pixel array. Basically I want some magical code to fill …
The End.