General C++ Programming - May 2011 (Page 14)

by peamon
template processor. How to do ?
 
Hello, I would like to créate a sort of Data processing template. But i would like my Processor type can be used as Class or Class pointer... How can i d...
[8 replies] Last: It's only the ownership of the processor that's parameterised. The in... (by kbw)
priority queue and structs
 
hello i have a pr. queue and a struct my struct is: struct Call { int CallNum; long CallTime; int CallLength; }; and I use priority_queue<C...
[19 replies] Last: buddy, i see what you want to say but i really dont know c++ syntax. i... (by whocares21)
Problem with passing class to a function
 
Hey guys! I'm new to C++ and I'm trying to solve a simple problem - calculate the distance between two points in a plane with known coordinates. Here is th...
[4 replies] Last: The compiler returns the same errors. Is there a possibility that the ... (by nightbreed)
by ThaG
GCC vs. LLVM
 
Why does this work with LLVM 2.0, but not with GCC 4.2 ?? #include <iostream> #include <vector> #include <list> using namespace std; bool compare(co...
[4 replies] Last: I don't think so --- but I could be wrong. All rules are off when it c... (by Duthomhas)
I need help - outputing the values of an array returned from a function
 
Hello, I am having a slight problem in the main programme outputing the values of the pointer to the array returned by the function generate_planet(ifstream ...
[4 replies] Last: Thanks Ne555! I will try the implementation for array creation that yo... (by anthony1947)
by haqim
Access to nested structures
 
I have a nested structure which I am unable to access. Do I need to create an instance of the structure type tDate? I have no idea how to achieve that. before A...
[3 replies] Last: Thanks to all for replies and the clarification. Now i remember havin... (by haqim)
code review
 
Can anyone review the following code snippet "security wise" and advice me on whether it is vulnerable or not: bool Processnput::onDecode(Stream* st, Bitmap* ...
[3 replies] Last: I don't know enough about bitmap processing to comment on the algorihm... (by kbw)
Best way to read file
 
Hi, I wants to read a text file which may be having 90,000 of lines but each line is having just a single word. I want to read that file using fstream, I wa...
[4 replies] Last: That might depend on the machine its going to run on. Many of the new ... (by Thazager)
renderSolidIcosahedron
 
I was working on some code for making an object using pre-existing freeglut code, namely the renderSolidIcosahedron() procedure in geometry.h. The code does mak...
[1 reply] : I fixed it just versing the order of the vertexes were drawn in. It lo... (by Thazager)
Pointer to a Pointer (MEMORY EDITING)
 
**REMOVED** Seems like this isn't the right forum to be asking for help with memory modification as no one seems to be able to help. I'll try elsewhere, thanks.
[1 reply] : How much time did you wait for the help to come? (by writetonsharma)
by aatwo
Program crashes after object is deleted
 
Hey guys. I have a program that is crashing a lot shortly after a temporary object is deleted. This immediately flagged in my mind as a memory corruption issue ...
[13 replies] Last: Use gdb. You are programming in Linux enviroment, so do I. Sooner or... (by b2ee)
question that is challenging
 
wanna get output for the following structure using c and c++ language * ...
[5 replies] Last: Another homework. (by b2ee)
urgently need help on the C++ question.
 
Hi All, Need expert to teach me how to solve the below C++ questions. Thanks (a) void Triangle (int, char) The function takes in two arguments, the integer r...
[7 replies] Last: For question (c) find length, if even then make a tempStr , for each l... (by Thazager)
Program Help; 2 fatal error regarding virtual/polyhmorphism code
 
This is an assignment that require students write in virtual function with at least one pure virtual function. I did a portion of the code, but when I compile, ...
[4 replies] Last: [co de] "Please use code tags" [/co de] You never defined those me... (by ne555)
File EOF with empty last line of file
 
Hello, I'm getting back into C++ using Eclipse and MinGW. My question is this. I am reading a text file. Some lines of the file have no data other can crlf. Fo...
[9 replies] Last: I don't really get why you are being so obtuse. If all you want is to... (by Duthomhas)
Help with crashing program...
 
Hey all, I am not yet finished with this program, but as it is, it crashes and I want to fix what is wrong with it before moving on. I maybe way wrong on this a...
[8 replies] Last: @ Moschops Well, thanks a lot for your help and I will go about worki... (by N1ghtm4r3)
Vector or Count?
 
Hello again, I'm wondering about the speed/efficiency tradeoffs of using the vector type, or simply using arrays and maintaining a separate element count. I ...
[5 replies] Last: The vector has to maintain a count, just as you propose to do it manua... (by kempofighter)
Making a c++ program read from a webpage (htlm file)
 
I've been reading a lot of info on how to take a webpage and have a program turn it into a text file, but none of it makes sense. Is it possible to create a C+...
[6 replies] Last: libCurl is widely used for this sort of thing and is open-source: htt... (by modoran)
Soda Vending machine Problem
 
I am having trouble with enumeration and array in my soda vending machine code. This program is composed of numerous functions, including inserting money, sele...
[7 replies] Last: bump (by jamahoe13)
Undefined reference to WinMain@16
 
I have seen posts about this problem before, and tried everything within them. This code is for my Freshmen (9th grade) free class, and I am making a simple ca...
[14 replies] Last: If you want to compile your code to a console program which runs, i.e.... (by anonymous23323124)
May 2011 Pages: 1... 1213141516... 32
  Archived months: [apr2011] [jun2011]

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