Beginners - September 2015 (Page 36)

by HG319
Move constructor and assignment
 
I have a project where I need to write a class which creates Matrices using a dynamic array. We need to write our own move constructor and move assignment opera...
[2 replies] Last: ... and you seem to continue your http://www.cplusplus.com/forum/begin... (by keskiverto)
by h4ever
LRESULT and extern variable
 
Can you explain me what means LRESULT? typedef struct COORDS_STRUCT { int x; int y; } COORDS; COORDS coords; ... coords = SendMessage(di...
[16 replies] Last: Thank you very much. Now it successfully compiled. (by h4ever)
Program if else hassle
 
Last question of the day. Whenever i press "Y" and go down path 1 i always get the error message from the "else" section. I want to continue with the program an...
[4 replies] Last: This is your code structure: if(character is Y) // Code Path 1 //No... (by MiiNiPaa)
by mykds
Copying Files
 
Hi there, today I've got a new problem and I can't see why it's not working. I've written my program and now want to write a little "installation-programme". ...
[3 replies] Last: Another effective technique is to explain your code to someone else. ... (by MiiNiPaa)
by ferrad
FILE in CPP
 
I have some C code which opens a file in the TEMP directory, writes to it and closes it. FILE* fp; char buff ; const char* env_p = getenv("TEMP"); strcpy(buf...
[2 replies] Last: Thanks, including cstdio did it. (by ferrad)
stop clock in sfml
 
hey guys below is a portion of the code where an enemy is created randomly on the screen after 2 seconds bt i want a max of 5 enemies on the screen but i dont k...
[1 reply] : Instead of stopping the clock you can check in the if statement how ma... (by Peter87)
Winapi MessageBox won't close.
 
So I'm finally buckling down and learning C++; and I already have extensive experience with Windows API from PureBASIC and Visual Basic 6, and in fact have used...
[1 reply] : In Windows MessageBox has the same meaning as Cancel button (or ... (by MiiNiPaa)
by new1
map case insensitive
 
Hey guys, I have a map called map<string,list> . i want to make case insensitive for map first element which is string my case insensitive as follows, i want...
[5 replies] Last: If it is just to display things, create a temporary map that sorts the... (by Duthomhas)
Goto statement confusion
 
Hey this is my second forum of the day. I hope that's cool, not trying to flood traffic. ANyway I'm confused by two things in this websites example of a go to s...
[5 replies] Last: To illustrate what's been said, here's a version of your program which... (by Michael5)
error class " " has no member function named " "
 
hey guys i need help....say i have a class bullet and in dat class i define a variable called attack_damage in bullet.h within public and i create an object in ...
[2 replies] Last: thanx for de reply il do just dat (by rofhiwangae)
Dynamic array container, with indirection.
 
How would I go about doing three levels of indirection with this array structure? I've never really messed with the array container and cannot find any examples...
[5 replies] Last: [quote=mishappp]I cant do that with the array container? If you don't... (by Peter87)
Odd errors, msdn solutions not working
 
I'm rebuilding my old random mapmaker for homeworld 2 from scratch as an exercise in refining my programming practices. No copy paste, pure rewrite, splitting o...
[5 replies] Last: Okay, after looking around, I bypassed the issue by completely rearran... (by DarkLightHitomi)
by Skip1
Header file issues
 
I can't seem to understand why I'm getting these errors with my header files. What am I doing wrong here? #include <stdafx.h> #include <iostream> // for st...
[3 replies] Last: Oh, and remove #include <stdafx.h> from your program. (by Kevin C)
Issues with program
 
Working on a program that combines everything i learned so far. I'm getting weird answers though //ultimate MATH PROGRAM #include <iostream> #include <...
[4 replies] Last: now im having another problem //ultimate MATH PROGRAM #include <ios... (by CrypticA1)
by ry0823
Void function?
 
I'm struggling to figure out why in the output, r == 2 j == 3 k == 2 r == 10 j == 2 k == 3, why the second time r would be equal to 10. Can anyone tell me why?...
[1 reply] : hideous. Use a debugger, inspect the variables (a watchpoint may be us... (by ne555)
Class in constructor won't decrease
 
When you run the program it prints out the same number twice and it seems like the constructor number doesn't decrease which is 100. Just run it it prints out 9...
[7 replies] Last: > q.buysomething(&q,o); a member function of a class receives as a h... (by ne555)
Unfamiliar errors
 
In trying to solve some errors, I came across a couple on the msdn site that I don't understand what they are trying say (well several, but most of them are cle...
[5 replies] Last: Well, that is interesting. Thanks. I looked up c++/cli and actually go... (by DarkLightHitomi)
by ry0823
Void function problem
 
I was told by my professor that the output would be "The value of total when i == 5 is -4 The final value of total is: 0 but I don't exactly understand why, c...
[1 reply] : i = 1, case 1, total = 6 i = 2, case 2 default, total = 0 i = 3, case ... (by closed account 48T7M4Gy)
Mathematical programming
 
Dear C++ users.. I am new using C++ and would like to know: How could I solve the following (simplified version of my) problem Max X*Y-X-Y subject to the...
[3 replies] Last: C++ is an imperative language, not a declarative one. You have to lear... (by Kevin C)
Merge Sort with display problem
 
Can any pros/senpai in c++ notify me why I could not call the display function to show the random numbers and sorted array? I squeeze out my brain juice yet sti...
[6 replies] Last: merge sort is O(n lg n) if the merge part can be done in O(n) The `dis... (by ne555)
September 2015 Pages: 1... 3435363738... 42
  Archived months: [aug2015] [oct2015]

This is an archived page. To post a new message, go to the current page.