| Who | When |
Messages | |
(not accepting new messages)
|
|
| Orgazmo
|
999
|
 |
|
11-10-2002 08:19 PM ET (US)
|
|
|
| Feihong
|
998
|
 |
|
11-10-2002 06:00 PM ET (US)
|
|
>>> Orgazmo /m997 <<< From what you've told me, it is probably an out-of-bounds error. The extra unused variable prevents the runtime memory error (seg fault) from happening, but it doesn't solve the underlying problem. You need to take a very careful look at how you are doing array indexing in that function. To change your mode (actually called Active Configuration in MS VC++), go to Build -> Set Active Configuration... then choose Win32 Debug.
|
| Orgazmo
|
997
|
 |
|
11-10-2002 04:27 PM ET (US)
|
|
Feihong, in that function, i was messing around and declared another variable which doesn't do anything. Just by doing that, the array comes out fine. Without this extra unused variable, it won't work correctly. DOn't make much sense. HOw do you choose modes? F5 for debug and F7 for build? I tried both, same problem.
|
| Feihong
|
996
|
 |
|
11-10-2002 03:24 PM ET (US)
|
|
>>> Orgazmo /m995 <<< Funny thing, that MS VC++. I should probably write up a How-To entitled "Commont Pitfalls of MS VC++ Programming". It probably wasn't a bug that you encountered, it was probably a "feature". When you are in Debug mode, all your uninitialized variables are set to random values (the same random values each time you start the program). However, when you are in Release mode, your uninitialized variables are set to zeroes. If you didn't mess with the Build mode at all, you are probably working in Debug mode. I recommend Debug mode because it's probably closer to how g++ works.
|
| Orgazmo
|
995
|
 |
|
11-10-2002 09:04 AM ET (US)
|
|
oh nevermind. SOB, MS C++ does have some bugs in there. its working now but its really weird.
|
| Feihong
|
994
|
 |
|
11-10-2002 08:56 AM ET (US)
|
|
>>> Orgazmo /m993 <<< I would need to know what your function looks like.
|
| Orgazmo
|
993
|
 |
|
11-10-2002 08:29 AM ET (US)
|
|
Feihong, a function were called with parameter 2D array. inside a function, values are assign to elements of the array. Outside of this function(in main), however, element of this array is different. can you tell me why and how to fix it?
|
|
|
992
|
 |
|
11-10-2002 06:42 AM ET (US)
|
|
Deleted by topic administrator 11-10-2002 08:13 PM
|
| Feihong
|
991
|
 |
|
11-09-2002 10:57 PM ET (US)
|
|
How to copy and paste on the Suns: 1. Select some block of text 2. Move your mouse cursor over the window in which you want to paste into. 3. Right click (middle click) on the window you want to paste into. 4. Note that the formatting of the code may not be preserved when copying from a browser window. This is not a Unix problem, it can happen on Windows too. You may want to save the source file onto your machine, then copy and paste to preserve the formatting of the code.
|
| |
Messages 990-989 deleted by topic administrator 11-10-2002 07:10 PM |
| Dirty-Vegas
|
988
|
 |
|
11-09-2002 06:58 PM ET (US)
|
|
Hey! Orgazmo you are absolutely right about what you said. Mr Reed thinks that we don't have a life and we shouldn't have a life at all, thats why he assigns prog. way too hard. He needs to chill out and realize once he was a student too. If I would spend all of my time writing program then I'll have "F" in all of my others classes and and I'll be w/o gf. And if he is willing to pay all my BILLS each month, then its absolutely fine with me.
|
| hairy munster
|
987
|
 |
|
11-09-2002 05:40 PM ET (US)
|
|
never mind, I get it!
|
| hairy munster
|
986
|
 |
|
11-09-2002 05:12 PM ET (US)
|
|
Feihong or the professor, in the guide that the professor give us to write the program, in step 2 it said that "..generate the random character one at a time, starting from top left and working down row by row, ending up on bottom right..." what does it mean to generate a rand character "one at a time"? any help is much appreciated!
|
| |
Messages 985-984 deleted by topic administrator 11-10-2002 07:13 PM |