General C++ Programming - October 2012 (Page 21)

postfix using arrays
 
HI i am doing a program which takes numbers from a user into postfix, using an array i cannot use the stack library. SO far i have the following i know i need t...
[no replies]
Opengl + SDL linking error
 
Hi, I am trying to load an image as a texture with opengl using c++ in visual studio 2010. I researched a couple hours online and found the SDL library, then I...
[no replies]
by mono
overloading operator =??
 
I am trying to overload the operator = in order to allocate memory ex Node ptr; ptr = new Node; But not sure how to do it with this struct part Priori...
[no replies]
Calculator (1,2)
 
Can Someone Give me a general idea how to go about starting this program. Please and thank you. 1. Let the user enter two integers from 1 and 12. V...
[21 replies] Last: moreover i used some default arguements which couldnt have been taught... (by SwatSid)
by h4344
Struct Variables Not Working in switch statement
 
I did a little debugging and i found that everything in my program works fine until i call this function, the function is supposed to set variables inside the s...
[3 replies] Last: Ok got it, i placed my playerid object after the struct playerid. st... (by h4344)
CMAKE - Installing podofo issues/Zlib??
 
I am trying to build PODOFO a pdf library. It requires zlib in the installation process. I'm using MingW on Windows XP. I have built zlib using the comman...
[16 replies] Last: OK... Some progress. In the zlib makefile set the below macros as fol... (by dominover)
Reading number from a file
 
Part 1 / Insert number to file // Reaper #include <iostream> #include <fstream> #include <iomanip> using namespace std; int main() { int num1; int ...
[8 replies] Last: ah ok i see, i understand how that works now, thank you my program wor... (by Reaper1)
tower of hanoi using stack
 
hello there i am making a game tower of hanoi using stack class not build in but user define in this program i have to get inputs from user to move the disks bu...
[6 replies] Last: thank u i've made it :) (by mehreenh)
Translating a C program to IA32 assembly language....
 
Okay so I have a C program, I now need to translate it to IA32 assembly languae..seems simple enough, except one thing... I have no idea where to start I have n...
[4 replies] Last: Keep in mind that your C program calls several library routines from <... (by AbstractionAnon)
by leoo
Count between arrays
 
I have a code that works like this: When the user does X in this game, we count Y of the player (Y = random number) Y is stored in a variable, e.g. it can...
[1 reply] : If you want to cache the last <n> values of Y, you're going to need to... (by AbstractionAnon)
insertFront func
 
I'm trying to create a doubly linked list. the issue im having is with the insertFront function which takes a listref and an int data (the value you want to add...
[3 replies] Last: No, you're not. Assuming that newNode assigns N->next=NULL; N->prev=... (by doug4)
Else error. Expected a statement
 
The else statement for "the customer does not have a discount coupon is underlined as incorrect. There is a missing or extra brace somewhere, but I can't find i...
[6 replies] Last: if (ticType == 1) {//if purchase toddler ticket ... } if (numTic ... (by doug4)
executable for other other exe
 
So, basically, it is like that. I am working shaders and I have an offline tool for compilation. Because I litterly have no idea how to make shaders to compile ...
[no replies]
by hungys
Any efficient way to do word count without STL?
 
I have to write a program that can show "top N most frequently words" in an article, and cannot implement with any STL container or algorithm. (N is depend on ...
[2 replies] Last: I would build a container as an ordered list. That is a list where ele... (by vlad from moscow)
Can't access variable created in class implementation file
 
Hello everyone, I am trying to create a const std::string in ONLY the class implementation file, and then access it through a static method for the class. I w...
[5 replies] Last: I confirmed L B's reply. Depending on the order in which I link the o... (by doug4)
HOW IS A BINARY TREE COPIED RECURSIVELY?
 
Hi everyone, the function below was taken from a Data Structures textbook by D.S. Malik and its function is to deep copy a binary tree. The problem I'm having i...
[1 reply] : The root node may or may not have a left node. It it does, that node ... (by doug4)
3 small question in C++
 
1. template<typename T> Interval<T>::Interval() { a = T(); b = T(); } what does T() mean? 2. the usually used name: 1)in copy structure,...
[5 replies] Last: I like to put 'o' (as "other") instead 'rhs'. (by morando)
by shafh
Pointer problem
 
Hi. I'm new to C++ and is currently having a problem. I have done the following get method: dagnode* dag::getVersionNode(int version){ dagnode *res = ...
[5 replies] Last: getVersion Node(x) returns a pointer, so you need to assign the return... (by BlackSheep)
Repair error please
 
#include<iostream> using namespace std; struct Node { int info; Node *link; }; class LinkedList { Node *first,*last; int counter; public: LinkedList(); bool isF...
[2 replies] Last: Thank you very much (by JAMES 23)
Logging Keystrokes efficiently
 
I'm making a game with the SFML libraries and i'm using it's RenderWindow class to capture the player's keystrokes. However, I believe it is what is eating up C...
[4 replies] Last: You might consider moving on to SFML 2.0 as well. I don't believe 1.6... (by cire)
October 2012 Pages: 1... 1920212223... 50
  Archived months: [sep2012] [nov2012]

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