General C++ Programming - April 2010 (Page 7)

if statement - not defined
 
I'm trying to use the if statement. As far as I am aware I am using it correctly, however I'm getting told Error: Identifier "if" is undefined Can someo...
[2 replies] Last: Thanks zoerb, the i was I. You can tell I knew to this :-) (by adamod67)
product check out program
 
ERROR: [Linker error] undefined reference to `FreshFood::FreshFood()' I dont really know why that error is returned yet everything seems fine to me.Its a...
[3 replies] Last: maybe your program just need a main() function? and delete the ";" in... (by qudongfang)
Understanding pointers and using them in a function
 
I am having a hard time with this. I need help with how to use pointers and if you could show me what I;m doin wrong I made an airplane seating chart and I want...
[1 reply] : In choose_seats function - your { and } don't match up. You are mi... (by guestgulkan)
mergesort.obj : error LNK2005: "void __cdecl X_mergesort(int * const,int
 
Hello world. This is my first post so I hope I do it right. I am working on a mergesort with linked list and had to code it in a certain way. I was given a Link...
[2 replies] Last: I guess problem is you're inserting .cpp file in your source. Try thi... (by Dufresne)
by ozair
i cant understand this compile time error
 
hello there, I am defining a class in a program similiar to 'string' class in standard c++ library <string> here is the code.. #include <iostream> using...
[5 replies] Last: A copy constructor must copy the contents of an existing object ( with... (by Bazzy)
Rating system
 
Hey I was just wondering if there was any way to implement a system where you can say somehthing like: Add "Rambo" 5 And that would save and then you could sa...
[6 replies] Last: Hmm... I would suggest using two separate maps for holding the command... (by m4ster r0shi)
by Null
I'm confused about this code.
 
Hello, I'm a little bit confused about this code: int fx(int a) { // do something } int main() { int x,y; fx((x,y)); // <------ } At first I tho...
[7 replies] Last: One use can be in for s, below is an example void reverse_string... (by Bazzy)
Simple Hangman Project
 
wrinnix (1) Apr 24, 2010 at 3:09pm I really need help with this project. I do not know where to begin at all. Below are the instructions from the tea...
[2 replies] Last: I wonder... When u see a double post, is commenting on both posts abou... (by m4ster r0shi)
by dkaip
a string problem
 
Hello, i have a litlle problem. Here compiler gcc says "error ... expected constructor, destuctor or type conversion before += ...". Why is that? Maybe because...
[4 replies] Last: Ok, i just understud this. Many thanh's. Jim (by dkaip)
What does this mean
 
hello all, New to C++ but have background in C. Can someone translate what this means? <vmime::ref<vmime::net::message> The whole thing looks like ...
[1 reply] : It's using namespaces and templates http://www.cplusplus.com/doc/tut... (by Bazzy)
by Phils
constructor problem
 
Hello everybody! I would like to ask a question about this code and some other questions related. I know this looks like a homework question but i just can't ...
[1 reply] : did you ever try any online tutorial?... there are soooo many good one... (by Incubbus)
Class Templates + Me = Frustration
 
I've written a class template for complex numbers, which has two private data members (real and imaginary parts) - in this program they are either ints or doubl...
[2 replies] Last: Ah, ok, I've declared i and j as doubles and that's worked. Thanks a l... (by xeroxface)
Serial Communication Code for Reading
 
Hi, does anyone has any simple C++ code to read data from serial port? I'm doing a project to receive a temperature reading for every 5 seconds from the serial ...
[5 replies] Last: They are both declared in windows.h (which itself will include the st... (by guestgulkan)
by jamjo
VC++ 2010 error
 
Hello Guys, I am making an application in new VC++ 10 and getting following error does anybody have any hint what it means to ?? Error 10 error C2252:...
[1 reply] : It is saying that you cannot explicitly instantiate a template inside ... (by guestgulkan)
by Groo
unidentified local variable
 
Hi guys n gals, I'm getting the "uninitialized local variable 'data' used" on line 26 and i can't figure out why. The program is supposed to read from a f...
[1 reply] : You are using arrays in a wrong way, see http://www.cplusplus.com/doc/... (by Bazzy)
List Implementation
 
below is the code which is same(almost) as given in MARK ALLEN WEISS #include<iostream> template < typename Object > class List { private: ...
[2 replies] Last: http://www.cplusplus.com/articles/how_to_ask/ http://www.cplusplus.co... (by Bazzy)
pseudo nos
 
Would be really grateful if anyone could throw light on how to write the method. Expression Evaluation Consider a pseudo code which takes following expres...
[1 reply] : this is easy once you see whats going on. except for the outermost ,... (by KrishnaV)
Undefined symbols: ld error
 
Hi, I have been struggling with this for quite a while now! Please help me figure this out. I have 4 directories, "app", "lib", "game" and "widgets". Here,...
[2 replies] Last: Okay, I tried that too. I put all the definitions in separate CPP file... (by pozdrav)
Change the variable inside a loop
 
Hello, I'm making a utility for my school to generate a script for out teleprompter. I need to change a variable inside a loop (I will highlight the variable...
[5 replies] Last: You need to change the name 'index' every time you use it: while... (by Galik)
by Jozo
usleep() problem
 
Hi all!! I want to make loading effect in c++. When I use this code, program works, but I want cout in one line. #include <iostream> #include <stdlib.h> us...
[3 replies] Last: Synchronizes the buffer associated with the stream to its controlled ... (by Mythios)
April 2010 Pages: 1... 56789... 24
  Archived months: [mar2010] [may2010]

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