General C++ Programming - November 2012 (Page 5)

problems with argc, *argv[]
 
Here's my code: const unsigned short NB_TOTAL_ELEMENTS = 81; int main(int argc, char *argv ) { unsigned short tableau ; for(unsigned short i = ...
[6 replies] Last: it's working thanks a lot! (by AeonFlux1212)
Operator []
 
Hey guys, i can't figure out how i do the overloading of the operator this is my code and what i tried to do: using namespace std; template<typename T, siz...
[no replies]
New C++ Program Free to Test (1,2)
 
This program took 3 months to develop and is now ready to be tested by other users. The purpose of this program is to make mathematical functions such as inter...
[25 replies] Last: and dont worry, i didnt get it either. i spent hours on the most trivi... (by Aramil of Elixia)
Unknown problem with vector pushback with class variables
 
Dear all, I'm writing a simple 2d sprite game in my spare time. I'm fairly experienced in C++ and I'm running into unknown and unexpected problems with a vec...
[10 replies] Last: I added debug code within the loop to print out "Area_Enemy = " and "E... (by Jutebox5)
Urgent need help please :(
 
So I lost alot of important information and it needs to be handed in the end of the week can someone do one of my programs for me while i work on the others, pl...
[8 replies] Last: ok my problem is with the cases some of the lines wont let me give any... (by Joshutsu)
set of functions
 
Consider this code: int main() { typedef std::function<void()> tvFun; std::set<tvFun> sFun; foo1 f1(3, 8.5); foo2 f2(9, 1.1); foo3 f3(21, 7.8); foo4 f...
[8 replies] Last: [quote=morando] return o.target_type() == f.target_type() If you're ... (by Cubbi)
by bbeth
Roman Numeral with Parallel Array
 
I am working on a program taking numbers and turning them into roman numerals both capital and lower case. here are my instructions: 1.user defined function "...
[2 replies] Last: pogrady-- I want to thank you for the information given! It has helped... (by bbeth)
binary file creation
 
i have a problem with the program creating a file #include <iostream> #include <fstream> #include <iomanip> using namespace std; struct record{ ...
[1 reply] : http://www.cplusplus.com/forum/articles/1295/ (by Zaita)
by LB
operator=(type &&)
 
When does it get used? Some googling gives me the move constructor, not this "move operator".
[3 replies] Last: It gets the same (well, similar) special treatment: http://en.cpprefe... (by Cubbi)
toupper compare array to string
 
I need to compare user input to an array and find the index. I want to use toupper bot having some trouble with the reference to array. This is the current l...
[5 replies] Last: The problem with that approach is that it has to modify both strings, ... (by andywestken)
Array problem
 
..jk
[no replies]
by doon
pointer error (1,2)
 
bool FindElement(int array ,int *ptr,int size); bool FindElement (int array ,int *ptr,int size) { if (size==0) return false; else if (arr...
[28 replies] Last: oh thanku (by doon)
How did you learn C++?
 
Please only people who know how to program well in c++ answer. Ive been looking for good sources to learn from but it seems that for every 1 good book there are...
[3 replies] Last: I recommend using C++ primer and Accelerated C++ together if your look... (by closed account 3qX21hU5)
Pointers to functions with unknown arguments?
 
Hi. I was wondering if it is possible to create a generic function pointer that can pass any given arguments to the function it points to. Basically: #inc...
[3 replies] Last: Whoa, that's a good one. Although I probably don't fully understand th... (by Ramses12)
How to pass a type as a parameter to a function?
 
For example: void AddService(Type type); And when I call the function send a type: AddService(int) I'm making a C# program to C++ program and ...
[no replies]
C++ programming loops, PLEASE HELP!!
 
Hi!! I have been trying to figure out for hours how to create a program in Visual C++ that allow to users enter 10 numbers between 10-50, and if the number ente...
[12 replies] Last: No problem, I was in the same boat when I started C++ also. I couldn't... (by closed account 3qX21hU5)
by noo1
Error: expected a declaration
 
Can anyone help me clear up this error please? It's popping up on line 3 in the code below: #include "stdafx.h" CheckingAccount::CheckingAccount(){ ...
[16 replies] Last: oh haaa, sorry about thet HTH. I've used it as "hope that helps" myse... (by noo1)
Why does the code escapes the second loop
 
So I have a multidimensional array which takes in the users input, the data entered are x and y coordinates of a point . heres the code only the loop part ...
[15 replies] Last: Yeah , I guess thank you so much for all the help (by nishantve1)
Strange crash...
 
Hi! I have the following code that crash, but when I put a std::cout..¡ Not crash ! #ifndef GECONTENTMANAGER_H #define GECONTENTMANAGER_H #include <...
[7 replies] Last: It´s true! Thanks! (by ShotoReapre)
Simple Binary Tree Delete with 2 Child Problem
 
So Im creating Simple Binary Tree, not BST. Im having problem in deletewith 2 child. Method for deletion is DELETE WITH COPYING. After deleteing, when I tr...
[no replies]
November 2012 Pages: 1... 34567... 51
  Archived months: [oct2012] [dec2012]

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