- Upvotes Received
- 0
- Posts with Upvotes
- 0
- Upvoting Members
- 0
- Downvotes Received
- 1
- Posts with Downvotes
- 1
- Downvoting Members
- 1
6 Posted Topics
Hi all, first thread in here. I usually don't open my executables with any sort of editor, but for the sake of curiosity I've tried opening one. And what I've found is not that funny: I've found myself able to edit every kind of string. Of course you have not …
Hi all, what is the best way to obtain all the possible 3-items groups out of 8 elements (0-7) with repetitions? This would be D'8,3 = 8^3 = 512 groups. I want to save them in an array, like [CODE]unsigned int array[512][3];[/CODE] What is the best approach?
If you want to initialize all the elements of an array to 0, you can use this [CODE]#define SIZE 5 int my_array[SIZE] = {0};[/CODE] Check out memset and memcpy also.
Hi all, how could you initialize, through a loop, a c array? For instance, say I have [CODE] #define SIZE 10 int test[SIZE]; for (unsigned int i = 0; i < SIZE; i++) { test[i] = 0; } [/CODE] How can I make use of some Assembly to loop through …
Personal suggestion: take your time to study at least the basics of c++. Here are just a few hints Instead of using [CODE]while((ch=infile.get())!=EOF)[/CODE] use this [CODE] std::string str; while (getline(infile, str)) { //Now "str" contains the entire line //... [/CODE] As for the character couting, try something like this [CODE] …
From the string you've written, I assume you're dealing with an SQL database. If that's the case, then you may want to use some library - google "c++ sql", and you'll find a lot of libraries along with tutorials (just to name some, ADO, ODBC...).
The End.
.It.