General C++ Programming - January 2011 (Page 23)

const int *
 
hi all and happy new year, i have this code template<class T> class A { private: int t; T typevar; public: A() {t=1;}; void set(const T a){typ...
[2 replies] Last: yes this helps!! thanks a lot.. (by vagelis)
can anyone convert this in C?
 
my friend helped me to make text twist in c and he created his own.. i dont know c++ so sad :(. He told me just convert it in C #include<iostream.h> #inc...
[1 reply] : Do you know C? If you do, it should not be hard to see that code above... (by kspangsege)
Linked list with and without destructor
 
I have a linked list like this: class list{ list *prevList; list *nextList; component *A ; } Now I want to have another linked list ex...
[2 replies] Last: I would probably declare 'B' and 'nl' to be of type 'list *' rather ta... (by kspangsege)
Program only works in C::B debug mode...
 
I've been working on this string class for a while now, and I just tried to compile its test file again. My program crashed, so I said "Well, alright, let's loo...
[5 replies] Last: In string::operator= resizedata(s<<1-datasize); warning: suggest p... (by ne555)
hangman...
 
hi guys... I have to write a programme that plays a game of hangman with following feeatures: 1.the programme start by reading from an input file a list ...
[3 replies] Last: This is not a hard program and you got a good set of the features. Wha... (by wolfgang)
by blyan
objects in memory
 
Hi all, does anybody know anything about exactly how and instance of a class is stored in memory (RAM)? I ask because I have a project to do for my degree...
[7 replies] Last: hi simeonz, I think I will probably be modifying the infrastructure... (by blyan)
AKS test discussion
 
ok, so I am writing psuedo code trying to recreate the AKS test. One issue I'm running into is that I want to be able to do it with doubles and long doubles if ...
[8 replies] Last: Then use relative error instead of absolute, or pass a smaller toleran... (by ne555)
by AJBats
Iterators for unknown stl container
 
Hello, I have a class that iterates through an STL container, begin() to end(). Very straight forward stuff. I was using a list originally, but the situation...
[3 replies] Last: The data in the container is actually owned by the user. This sou... (by Disch)
by Gust02
wraparound number !!?
 
Hi.. I a student in the Universty and my teacher gave me a crazy qeustion that I spent long time on it to find the idea which lead m to solve this problem ......
[7 replies] Last: I made you a programming paradigm. http://www.cplusplus.com/forum/lou... (by Kyon)
by Icenel
Password disguise
 
Hi, i am new to C++ and I have just make Password program like this : #include<iostream> #include<stdio.h> #include<conio.h> using namespace std; void ...
[6 replies] Last: Hi there, this is a bit untidy and dirty code...but will do the trick.... (by Celtc)
by Celtc
*Char Variables Overwritten?
 
Hi everyone, I'm having a problem. I'm trying to get three differents *char in order to check if they math between themselves ( actually just to check two of th...
[2 replies] Last: Thank You!! I didn't know that the pointer fpass remains with the same... (by Celtc)
by dodo
plz do this project
 
Project Description:- • This project manages the bank activities. • The bank has many branches. • The bank deals with many account holders and each hol...
[19 replies] Last: It is not even remotely moral to write the code for you (, nor would I... (by simeonz)
by pizet
Arithmetic expression
 
Hi, guys. I'm making a program that will evaluate an arithmetic expression. My algorithm converts the infix representation into postfix first and then procee...
[4 replies] Last: Final version. bool readElement(int& value,char& character) { ch... (by pizet)
Derived Classes with 1 member different
 
Hi, I have 2 main classes: BookShelf and Library. Both these classes need to have a member class which would be BookList. Now BookList is a linked list with...
[5 replies] Last: Hi Naraku, Sorry I didn't understand. Which library? (by aryajur)
by acorn
pure virtual question this time
 
Would it be correct to always use pure virtual instead of just virtual in a base class if the virtual function definition of the base class does nothing. assumi...
[2 replies] Last: thanks for the insite. i will certainly give more thought to the actua... (by acorn)
by acorn
question about virtual keyword
 
lets say i have a base with a virtual function. when i implement that function in the derived class many examples dont use the word virtual in the derived cla...
[3 replies] Last: I tested it with a more advanced example using polymorphism and you ar... (by acorn)
fstream getline(..) segfault
 
Hi all, This is probably a rookie mistake, but I've googled by heart out for an hour now and nothing seems to fix my issue. I'm getting a segfault when I ca...
[6 replies] Last: hey all, Thanks again for the advice. Personally, I prefer K&R, bu... (by chisser98)
goto and exception
 
Hi i have always read that one should avoid goto. But i don't come to know the reason y? some say its degrade the readability, that's right. But what i wan...
[14 replies] Last: If you are using C++, stick with exceptions. If you want exceptions... (by Duthomhas)
Keyboard handler
 
Is there a header or library that supplies access to the keyboard so that a program might capture statistics from the keyboard? In other words, can i gather inf...
[1 reply] : If you are using Windows, you need to install a "system" (aka global) ... (by Duthomhas)
by akramm
A bug in the program is open
 
hello why when I create a program with Dev-c + + and I run it doesn't work What do I do?
[4 replies] Last: spray insecticide to the bug so that your program will work smoothly. ... (by joeneldeasis)
January 2011 Pages: 1... 21222324
  Archived months: [dec2010] [feb2011]

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