General C++ Programming - October 2013 (Page 22)

[] and = operators together
 
Hello guys! I wanna use and = operators together. className x(); x = value2; How I can do it and get two values in my class?...
[2 replies] Last: Do you want to overload two operators in your class? In the code snipp... (by abhishekm71)
Indenting code
 
Do most people do it manually or use some sort of software?
[5 replies] Last: Generally my IDE (VS2008, Notepad++) does it for me while I write. Wh... (by Stewbond)
Map Program
 
I've been working on this for awhile now. I can't figure out what I'm doing wrong. #include <iostream> #include <string> #include "calc_distacne.hpp" #...
[1 reply] : Haven't looked at anything else in the program except for noticing tha... (by JLBorges)
Question about emplace_back()
 
My understanding is emplace_back() will neither copy nor move objects. It constructs the object in-place. So following code should compile: class Person { p...
[3 replies] Last: > It doesn't quite make sense to me. The whole issue of implicitly ge... (by JLBorges)
by CroCo
Deleting an object?
 
I'm accessing a memeber function of an object that has been deleted. My question is why the compiler didn't complain? I'm using Qt. #include <QDebug> #i...
[5 replies] Last: To help detect errors of this kind, use (ideally more than one) static... (by JLBorges)
Orwell Dev C++ won't compile or recognize my commands
 
I was hoping someone could help me. I get a bunch of annoying error messages when I try to compile a program C:\Users\Public\Documents\C++ Shizzle\main.cpp I...
[5 replies] Last: stdafx,h can be completely ignored. It is not a library or required, i... (by closed account S6k9GNh0)
Calendar Program
 
Hi, So for my C++ class I am required to create a program that will "Write a program to generate a calendar for a year. The program should accept the year and ...
[3 replies] Last: I am required to create a program that will "Write a program to gener... (by xismn)
Using non-static member function pointer to define function
 
I want to use the gnu scientific library for minimization, but I want to wrap it in an adaptor so that I can easily use a different implementation without chang...
[no replies]
Help with homework
 
Can someone please help me with this homework? I don't know where to even begin. I don't want someone to do it for me, just tell me how I should do this. Than...
[5 replies] Last: I cannot access the readings, but this homework appears to be a depart... (by Duthomhas)
list container question
 
Hi, I've been looking through containers in the reference section and I can't figure out how to access (i.e. READ) elements in a list... any advice? Thank...
[2 replies] Last: Thanks a lot, found a nice example in http://www.cplusplus.com/referen... (by AeonFlux1212)
Next Fit Memory allocation help needed
 
Hi, I am writing a program that does all the memory allocation fits. So far I've done First Fit, Best fit (both static) and worst fit(dynamic). I am complete...
[no replies]
by trey28
help! advice
 
Ok so I never learnt programming in high school but I'm an electrical engineering major and there are quite a few programming classes that are required. I'm on ...
[2 replies] Last: Ok great. Thanks a lot! I will definitely check that out. Hopefully i'... (by trey28)
Storing data from 2 columns in a .csv (1,2)
 
Originally posted in beginners with no luck - I have a file that can range from 100 rows to 10000+ that is comma delimited with 8 columns. The first 32 rows (a...
[30 replies] Last: Of course you are right keskiverto. Though my previous code requires v... (by Chervil)
Help With Payroll Program Please
 
I am making a payroll program as a project for my class. We are being given a list of data in one file and are to output the payroll information in another fil...
[4 replies] Last: Thank you so much for the help!! (by mdonovan23)
Class using Class
 
I have class called student that has lastname,firstname,credits,gpa,date of,birth, matriculation date. I have another class called roster that has course name ...
[no replies]
delete this;
 
Is this a terrible idea? I have C entry points into a C++ applications. The child classes should be used like so: MyClass* g_mod; MY_API void init() { g...
[4 replies] Last: @Disch Ooo, didn't think of std::unique_ptr It should be your first... (by Disch)
Game {Blackberry}
 
Hello im developing a blackberry Game ... im confused with something i want to make a level thing for example player is now level one if he ...
[2 replies] Last: alright for example i have a riddle game when you start the game i... (by thelop96)
get name of FILE* in c
 
so i have an array of files stored in a FILE* and need to check if they exist. if they dont, i want to print an error, but i dont know how to get the name which...
[6 replies] Last: Why are you using C FILE * when you could be using C++ file streams o... (by closed account Dy7SLyTq)
I need serious help
 
I seriously suck at programming. Why won't this compile? I don't understand why it thinks it isn't declared within the scope.... I am using.. g++ --std=c++0...
[10 replies] Last: The problem is that the command you gave was to try to build an execut... (by doug4)
Can anyone help me find a bug in 8086 CPU emulation?
 
I'm trying to find some bugs that seem to be in my 8086 CPU emulation (flag operations and group opcodes copied from fake86). Can anyone help me find the error(...
[no replies]
October 2013 Pages: 1... 2021222324... 46
  Archived months: [sep2013] [nov2013]

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