General C++ Programming - June 2016 (Page 4)

Understanding Statements
 
When reading the problems to convert to C++ how do I know which statement to use? ex. when the pr...
[1 reply] : Your question is akin to asking "I have this story I want to write. Ho... (by helios)
code robustness and const keyword
 
This question is out of place: the thread was closed before I noticed it! Sorry. IDM says: Us...
[5 replies] Last: Some other basic ideas about robust code. An overall thought is: What... (by TheIdeasMan)
Find the logic errors
 
This is example code from "Principles and Practice using C++" by Bjarne Stroustrup, and we're suppos...
[8 replies] Last: Never mind. It's working! (by lbourbon)
Question about using variadic templates with template patterns
 
In trying to solve my latest programming dilemma I learned about variadic templates. However, I hav...
[5 replies] Last: #include <iostream> #include <typeinfo> #include <type_traits> #inclu... (by JLBorges)
by wakeup
An ATL class as member of another ATL Class
 
I have an C++ ATL COM DLL (VS2015) with two ATL Clasess, and I would like to add one of them as a me...
[no replies]
by Vabi
unable to return string from function
 
Hi, I have tried a program in which I wrote a function to get name from user and then I want to r...
[4 replies] Last: Exactly, that's the reason I did it that way! XDD (by closed account 48T7M4Gy)
How do I refactor two classes with similar functionality?
 
I have classes with methods with the same names that do the same thing yet they are implemented diff...
[3 replies] Last: I believe you can use a template interface with pure virtual functions... (by primem0ver)
How to run through a two dimensional matrix by using pow(2,n)?
 
I am trying to run through an array and its dimensions are being created as the program runs. I want...
[3 replies] Last: Thanks! It was solved! (by Poetjockey)
by rpsalh
acos not working
 
i was making program calculate basic things about shapes but when i used acos() for calculating ang...
[8 replies] Last: Cheers, I'm glad you found it. :) (by closed account 48T7M4Gy)
binary search tree insert complexity
 
Could somebody please help me do a complexity analysis(deduction) of the insert algorithm of a binar...
[5 replies] Last: Never mind. I think I know it now. It's like 1+2+2^2+...2^k = n. That ... (by closed account GTMi1hU5)
Templates - Help
 
Hi there, I have a question about templates and I have been banging my head against a wall with this...
[9 replies] Last: H i and thank you for all the replies, btw fcantoro I know my origina... (by newbie78)
specifying header filepaths for MANY different paths
 
Hi guys. I'm trying to get a library I've downloaded to work with a project in Dev-C++. The proble...
[6 replies] Last: > OpenCV has too many directories for me to drag and drop into a diff... (by ne555)
by noob96
C++ Error: call of overloaded function is ambiguous
 
I have defined a function in one file - void c2bc( std::string& filename, std::string& outname ) ...
[10 replies] Last: It turns out I actually wanted to call parse_cpp_file function and not... (by noob96)
Help for memory management
 
Hi In the code below ,my question is when i delete sss , what happens to allocated memory for "*x" i...
[3 replies] Last: Yes. A class is identical to a struct in every way, save one: the de... (by MikeyBoy)
by elay
help about best way
 
is it only okay for setter function definition to be more than 1 line? void Class::setter(c obj) {...
[4 replies] Last: i was thinking about which one is the best way First what happens, i... (by jlb)
memory allocation for array
 
How do I make a million ints? I can't do it with subscripted arrays. I can with dynamic memory alloc...
[8 replies] Last: Hi, Note that the pass by reference should be used for any of the STL... (by TheIdeasMan)
Frequency counting in large arrays
 
Hi! Alright, so i'm just starting a data structures class, and we're studying arrays. We were asked ...
[13 replies] Last: http://www.cplusplus.com/reference/algorithm/set_intersection/ (by closed account 48T7M4Gy)
How to initialize a vector of structs with user data
 
I would want to initialize the following struct with user data using a vector of strings as below, h...
[3 replies] Last: You'll have to iterate through the vector (use a for loop) and check... (by Duthomhas)
by yiddo
Unknown mistake from a Textbook example
 
Hello guys. I'm involved with C++ for about 3 weeks by now. So far i enjoy the learning process. Som...
[4 replies] Last: I thought that my compiler is set by default for C++ 11 version, appa... (by jlb)
long long integer is down casted to int
 
Hi, The below program is used to count the no of inversions in an array.The program works fine for ...
[2 replies] Last: Yeah,Thanks that was the problem. (by abhisheksinghbiet)
June 2016 Pages: 123456... 14
  Archived months: [may2016] [jul2016]

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