General C++ Programming - December 2016 (Page 14)

How can I place lambdas in header files without generating multiply defined symbols from the linker?
 
Hi, I need to have definitions (or declarations) of lambdas placed in header files so I can use the lambdas in several cpp source files, but I get multiply d...
[4 replies] Last: Great reply PanGalactic!! Thanks a lot for the clarification Juan (by JUAN DENT)
by Luis R
C++ with user form
 
hello, to all please help me for this program.. I need to make a program with a form that the user enters a number and it validates if it is even or odd. ...
[8 replies] Last: Here is a simple way to do it. Try if you can run it. https://www.drop... (by Thomas1965)
object oriented C++ practice problems
 
Hello world! I try to find over the Internet a website that has practice problems on C++ classes and object (+inheritance,+polymorphism), but I can not find ...
[2 replies] Last: Thank you coder777 (6062), very interesting link, but I am looking for... (by orestis987)
ppm file view
 
Can i view a ppm file in format to check that the values that i store in the buffer are the same?
[2 replies] Last: #include <iostream> #include <fstream> #include <string> #include <ve... (by JLBorges)
by radhio
Input title data for Excell
 
Im too beginner in C++. How i need add title data for this code : void ReportDefectPanel::ExportRawData(IReportWriter* pWriter) { if(mStatisticData.empty())...
[1 reply] : Double post http://www.cplusplus.com/forum/beginner/204050/ (by SamuelAdams)
Help in array and function...
 
I am extremely new to this forum...help needed... I know how to pass an array in function definition... but how to return an array from the function to the mai...
[6 replies] Last: Thanx to all of you...i got it...yeah... (by kinjal2209)
need assistance forcing the user to enter the correct input with a cstring
 
Im trying to preform a do-while loop that forces the user to enter the correct file name using a c-string. but for some reason it works for those that are wrong...
[19 replies] Last: @Chervil. That's an interesting approach too. It's interesting how ign... (by closed account 48T7M4Gy)
Hangman
 
Hangman Pseudo Code 1. Do a nice introduction screen for your hangman program (do this step last). 2. Select a random word and store it in a string variab...
[1 reply] : i have done this much so far #include <iostream> #include <time.h> #i... (by peter159)
relpy thanks
 
I am stuck I cant run my code I need help!!! thanks #include <iostream> #include <string> #include <iomanip> #include <cstdlib> #include <stdio.h> #includ...
[8 replies] Last: Example use of the functions above: #include <iostream> #include <s... (by boost lexical cast)
by Rikasi
Class Scope-Can a super class type reference be used to refer to one of it's subclasses?
 
Can a super class type reference be used to refer to one of it's subclasses? e.g class superclass { virtual void delete_subclass()=0; }; class sub...
[6 replies] Last: That doesn't sound like a very fun game. Assuming that this is actua... (by mbozzi)
Vector
 
Good morning guys! Good Morning, guys! Soo I have simple game in which I create bunnies. For each female bunny theres a male bunny born. They age one year...
[5 replies] Last: Hey,man, I don't think it's working. It still does miss a lot of them ... (by Tomheza)
Converting char to int
 
I am writing a program for a Finite State Machine. The machine gets an input of either 'a' or 'b' from a text file. I need to convert this character into an int...
[1 reply] : The machine gets an input of either 'a' or 'b' from a text file. I ne... (by cire)
Programming Final Project for Beginner-level Class
 
Hi there. New to the forum with a request. I have a project due Thursday and I am lacking understanding of the material needed to complete it. I am basicall...
[1 reply] : You are, of course, free to respond to the troll who keeps posting spa... (by cire)
by mkb555
Delete elements from dynamic array
 
I've seen topics on this before, but never seemed to get a definite answer. I have a 2D space represented by a 1D dynamic array. I need to be able to delete col...
[2 replies] Last: As in shift every column ahead of the one I'm deleting back by one ind... (by mkb555)
Multiply defined symbols error
 
I am writing a program and I need to put certain things in different .cpp and .h files but when I try to seperate certain things into .cpp files I get an error ...
[2 replies] Last: Ok got it! Thanks so much for the help and information! I spent so m... (by trno224)
I want to create a create a compile time vector that associates a type and a lambda with an index
 
Hi, This is the code I have now: auto processingObj = process(selectCriteria, lines); switch (col) { case Columns::Date: { processingObj.fi...
[6 replies] Last: Big thanks mbozzi !! Incredible example!! Juan (by JUAN DENT)
by srcs
accessing a private structure in a class using member function
 
Trying to write a setter function for a private structure inside a class. Haven't found a declaration method that allows access to the structure. The structu...
[2 replies] Last: Lines 10,28,46: Why are you creating a global instance of you class c... (by AbstractionAnon)
Monitor cpu, memory and handle
 
Hi, How to monitor consumption cpu, memory and handles in language C? Thanks
[1 reply] : In what operating system? If you're asking about Windows, the Windows... (by AbstractionAnon)
string
 
I need help with this code,,, #include <iostream> #include <string> #include <iomanip> using namespace std; string reverseString(string i) { string ...
[7 replies] Last: thanks guys!!!! (by codeerror)
December 2016 Pages: 1... 1213141516... 18
  Archived months: [nov2016] [jan2017]

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