Forum: C
Aug 17th, 2005, 2:15 PM
|
|
Replies: 11
Views: 383
|
Forum: C
Aug 16th, 2005, 3:00 PM
|
|
Replies: 6
Views: 496
|
Forum: C++
Apr 22nd, 2005, 5:15 AM
|
|
Replies: 12
Views: 289
|
Forum: C
Apr 8th, 2005, 6:51 AM
|
|
Replies: 7
Views: 276
This is not strange at all. You must allocate...
This is not strange at all. You must allocate memory before you can free it.
If you crete a character pointer (char *neu;) it is pointing to some undefined memory location.
b.t.w. you can use neu...
|
Forum: C
Apr 5th, 2005, 6:54 AM
|
|
Replies: 5
Views: 397
Just a small note:
1. Do not use the fflush...
Just a small note:
1. Do not use the fflush function on input buffers, this is undefined behaviour.
2. Never use the gets function, use the fgets function instead.
To flush the input buffer, you...
|
Forum: C++
Mar 20th, 2005, 1:06 PM
|
|
Replies: 17
Views: 389
|
Forum: C++
Mar 8th, 2005, 4:14 AM
|
|
Replies: 9
Views: 290
|
Forum: Visual Basic
Mar 7th, 2005, 3:54 AM
|
|
Replies: 2
Views: 209
Data Type Summary...
Data Type Summary (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vbenlr98/html/vagrpDataType.asp)
|
Forum: C++
Feb 9th, 2005, 1:14 PM
|
|
Replies: 1
Views: 186
|
Forum: C++
Feb 8th, 2005, 1:27 PM
|
|
Replies: 15
Views: 1,029
|
Forum: C++
Feb 8th, 2005, 1:21 PM
|
|
Replies: 15
Views: 1,029
I have made some changes to the code (in red)....
I have made some changes to the code (in red). It's now reduced to 1 error:
error C2061: syntax error : identifier 'monster'
You need to add a function to Monster.h: int get_bonus_damage();
And...
|
Forum: C++
Feb 7th, 2005, 4:50 PM
|
|
Replies: 15
Views: 1,029
|
Forum: C++
Feb 7th, 2005, 4:44 PM
|
|
Replies: 15
Views: 1,029
Are you sure, because that's exactly what the...
Are you sure, because that's exactly what the compiler tells you: local function definitions are illegal
I have added and extra } just before the int player::fight(monster *m) function and it...
|
Forum: C++
Feb 7th, 2005, 4:38 PM
|
|
Replies: 15
Views: 1,029
|
Forum: C++
Feb 7th, 2005, 4:22 PM
|
|
Replies: 15
Views: 1,029
|
Forum: C++
Feb 5th, 2005, 3:16 PM
|
|
Replies: 5
Views: 325
|
Forum: C++
Feb 5th, 2005, 3:08 PM
|
|
Replies: 5
Views: 325
|
Forum: C++
Feb 5th, 2005, 2:34 PM
|
|
Replies: 5
Views: 325
|
Forum: C++
Jan 28th, 2005, 11:09 AM
|
|
Replies: 11
Views: 792
You are (almost) correct. The values are not...
You are (almost) correct. The values are not passed correctly to the separate function.
That's because you are passing the complete struct. What the program will do is create a copy of the struct...
|
Forum: C++
Jan 23rd, 2005, 2:00 PM
|
|
Replies: 3
Views: 239
To prevent generating the same random numbers...
To prevent generating the same random numbers each time you start the application, call the srand function before the rand function:
#include <cstdlib>
#include <iostream>
#include <ctime>
using...
|