51,593 Topics

Member Avatar for
Member Avatar for centraspike

Hello, I need some help writing code for a stack using link list implementation without using the STL. Basically what the stack would do is to convert an infix expression to postfix and then show the results of the operation. The stack should utilize a class not a struct. I'm …

Member Avatar for mrnutty
0
124
Member Avatar for sleepybug

i m trying to do this program to get digits from a number using linked lists..but don't know something is wrong.a logical error:-/ at the place of actual output it shows nothing clear blank ecept the message.so here's the code: [CODE] //DigitNode.cpp # define NULL 0 class DigiNode { private: …

Member Avatar for mrnutty
0
132
Member Avatar for tikoti

Hi, I am having an issue with a program and I have ended up realizing I don't know how to pass an array as a parameter. It seems that when I do it the arrays length is one inside of the function, even though outside is different. Here is the …

Member Avatar for mrnutty
0
160
Member Avatar for SKP

I am using map <string, string> to create a map. Inserting and finding operations work fine on solaris, aix but core is generated on hpux. The error shown in core debug as follows: insert__7rb_treeXT12basic_stringXTcT18string_char_traitsXTc_T9allocator_T4pairXTC12basic_stringXTcT18string_char_traitsXTc_T9allocator_T12basic_stringXTcT18string_char_traitsXTc_T9allocator__T9select1stXT4pairXTC12basic_stringXTcT18string_char_traitsXTc_T9allocator_T12basic_stringXTcT18string_char_traitsXTc_T9allocator__T12basic_stringXTcT18string_char_traitsXTc_T9allocator__T4lessXT12basic_stringXTcT18string_char_traitsXTc_T9allocator__T9allocator_FRC4pairXTC12basic_stringXTcT18string_char_traitsXTc_T9allocator_T12basic_stringXTcT18string_char_traitsXTc_T9allocator__ () Has anyone faced the same issue and has got the fix for it??? Please share …

Member Avatar for Salem
0
140
Member Avatar for spartan118

Figured problem out. Please delete post. -- original text -- hey all I'm a novice C++ programmer and I'm stumped on a console app I'm trying to build [CODE]#include <windows.h> #include <stdlib.h> #include <tchar.h> #include <iomanip> #include <stdio.h> #include <time.h> #include <Winuser.h> #include <atlbase.h> #include <iostream> #include <conio.h> #include <direct.h> …

0
67
Member Avatar for daviddoria

When compiling some working code on Fedora 11, I am getting this error: [code] /usr/include/c++/4.4.1/cstdarg:56: error: ‘::va_list’ has not been declared [/code] I am using: [code] [doriad@davedesktop VTK]$ g++ --version g++ (GCC) 4.4.1 20090725 (Red Hat 4.4.1-2) [/code] Does anyone know what the problem could be? Thanks, Dave

Member Avatar for daviddoria
0
1K
Member Avatar for maharjun

i tried making a string class but my program seems to be repeatedly crashing. why so? I have the following two files in to my program 1.)Strng.h (in INCLUDE directory) [CODE] #ifndef __STRNG_H #define __STRNG_H #if !defined(__CONIO_H) #include <conio.h> #endif #if !defined(__STRING_H) #include <string.h> #endif #if !defined(__STDDEF_H) #include <stddef.h> #endif …

Member Avatar for mattjbond
0
181
Member Avatar for endframe

Hi all, I need some help finishing this program, I know it's easy but I'm new in C++ and programming. [CODE]#include "stdafx.h" #include <iostream> using namespace std; int main() { const int arraysize = 10; int a[arraysize] = {11,22,33,44,55,66,77,88,99,100};[/CODE] This is the start of my program ; a giving array …

Member Avatar for endframe
0
206
Member Avatar for marcel222

Hello all, I have a question about coupling C++ classes to a GUI, in a nice Object Oriented solution. The problem is as follows: I have designed a GUI application in a separate class Gui for instance, in a other source file I designed a hierarchical statemachine for my GUI …

Member Avatar for Ancient Dragon
0
160
Member Avatar for pato wlmc

Well first of all, hi, and thanks to all of you guys, cause this may be the first time I start a thread, but not the first time that one of you solve my problems. Anyway. I'm following an internet tutorial about API development, ( [url]http://www.winprog.org/tutorial/menus.html[/url] ) But rigth now …

Member Avatar for mitrmkar
0
714
Member Avatar for nike_jj4

Hello! I have the following problem> I have this 3 structures: [code] struct student { char name; int index; }; struct modul { char mod_name[10]; struct student st[10]; }; struct faculty { char fax_name[20]; struct modul mod[3]; }prom; [/code] ------------------ My question: How can i reach the name of the …

Member Avatar for nike_jj4
0
86
Member Avatar for chinnaedu

hello all I am looking for a sample C code for packet interceptor.... Any help is appreciated Thank you

Member Avatar for chinnaedu
0
87
Member Avatar for jiten_raulo

Can any one tell me how to put a part of program into a header file or how to work with multiple files? According to my book, I need to put the template and class part into a separate file and include the header as "counter.h". I have done same …

Member Avatar for jiten_raulo
0
140
Member Avatar for arunbt
Member Avatar for Nick Evan
0
54
Member Avatar for Christoph928

I have an assignment to write a C++ program that will ask the user for the name of a data file. This data file contains a list of drivers. The names are listed, one per line, in the following format: lastName firstName middleInitial and each part of the name is …

Member Avatar for WaltP
0
198
Member Avatar for karolik

So I have a LinkedQueue which is a queue that is implemented by LinkedList. I need to overload the = operator for LinkedQueue. [CODE]LinkedQueue& LinkedQueue::operator=(LinkedQueue& queue) { return *this; }[/CODE] As you can see Linked Queue is const...the problem is that in order to copy the content from queue to …

Member Avatar for mattjbond
0
117
Member Avatar for chinnaedu

hello all.... is there any possibility to get the entire packet as such when data is sent (since its sent in the form of packets) including the details like source ip,port etc...atleast from IP header.... cos i want to receive the packet and send the same packet as such to …

0
56
Member Avatar for Mridula J

Hi All, Refer me a good C++ book, specially for Exceptional Handling. thanks mridula.

Member Avatar for gnarlyskim
0
72
Member Avatar for gizgiz

[b]Purpose of the program:[/b] This program is supposed to use a void function called removeLetters to remove both uppercase and lowercase letters from a given string. The function isn't allowed to use square brakets (ie no arrays) and the only (1) local variable allowed must be a pointer. [b]Problem:[/b] The …

Member Avatar for gizgiz
0
139
Member Avatar for JHus00

[CODE]if (windspeed <= -40 && windspeed <= 40) { windchill = calculate(temp, windspeed); output(temp, windspeed, windchill); } else cout << "Error, please enter a number between -40 and 40 for temperature";[/CODE] I need to check to make sure a number, windspeed, is between -40 and 40. Can I do this …

Member Avatar for Ancient Dragon
0
92
Member Avatar for delhiris

HI Please tell me how to connect to database(i.e table) using graphical enviorment in c++.net

Member Avatar for Ancient Dragon
0
51
Member Avatar for gnarlyskim

I have to be able to read text from a file then manipulate it to find the average value of an integral over a given bounds [a,b] from an input file, then export it to another file. I do not know how to store the information to process it. Say …

Member Avatar for gnarlyskim
1
185
Member Avatar for rockstar8577

Hello i'm having trouble reading from files from fstream. I want to skip a word but don't know how to do so with input from files. [code] myfile >> avatar.name >> avatar.name >> avatar.name; myfile >> avatar.hp >> avatar.hp >> avatar.hp; myfile >> avatar.mana >> avatar.mana >> avatar.mana; myfile >> …

Member Avatar for jonsca
0
85
Member Avatar for sdgz747

I am supposed to be writing a program that will calculate sales in a week. Every week 200.00 dollars is earned, then sales is calculated on top of the 200.00 (i.e., 5000.00 in sales, would be 200 + .09 * 5000.00). My code is below, but I am having problems …

Member Avatar for sdgz747
0
97
Member Avatar for sdgz747

I wrote the following code for a homework problem, but it's stuck in an infinate loop. I'm not sure how to correct that problem. The other issue is I want the answer to be given in two decimal places and not rounded in any way and it appears that my …

Member Avatar for sdgz747
0
119
Member Avatar for daviddoria

I am trying to compile some software I found online. I am getting a bunch of these errors: [code] No rule to make target `/usr/lib/gcc-lib/i386-redhat-linux/3.2.2/include/stdarg.h', needed by `formCluster.o'. Stop. [/code] In the Makefiles, there are certainly lines like this: [code] transform.o: /usr/lib/gcc-lib/i386-redhat-linux/3.2.2/include/stddef.h [/code] The errors seem to go away if …

Member Avatar for daviddoria
0
404
Member Avatar for whoamineo89

Hello oh helping minds I have a dilema...I've got to create a C language address book and not C++ or turbo C...I've already done a majority so far but I need help with a certain problem if there are any other problems please let me know. I keep getting an …

Member Avatar for Ancient Dragon
1
5K
Member Avatar for sandeshps

I'm going to build a text editor in Turbo C++ 3.0 , but i don't know how a text editor works . I want to know the working of text editor , any tutorials ? Please help

Member Avatar for Ancient Dragon
0
46
Member Avatar for lethal.b

i am trying to create a function that i can put in my program but i have got myself stuck. basically i have a string that contains letters. for example 'gototheshopatnoon'. from that string i need to transfer all the letters to another array and discard any duplicate letters. so …

Member Avatar for WargRider
0
111
Member Avatar for XinJiki

I have a homework assignment that where I need to find the longest word that has the most amount of consectutive vowels. here is the description: The text file words.txt contains an alphabetically sorted list of English words. Note that the words are in mixed upper and lowercase. Write a …

Member Avatar for Ikejae
0
1K
Member Avatar for zoooz321

How can i get a file from a server (any machine) using ftp in C++ i searched alot in ftp in C++ but i got a huge cpp files and header files ana i dont understand so much from there.. and my Dr tell me that i need a small …

Member Avatar for vinumi
0
106
Member Avatar for noyfb

[code] #include <iostream> #include <vector> using namespace std; int main () { int N =0; int Range=0; int NumberOfCases=0; cout << "Enter N" <<endl; cin >> N; cout << "Enter Range" <<endl; cin >> Range; cout << "Number of cases" <<endl; cin >> NumberOfCases; vector<double> range_time_Vector(Range); int K = N; …

Member Avatar for noyfb
0
122
Member Avatar for farad

Hi there guys thanks for you help. Basically I have created a c# form based rot13 encryption program. The problem I am having is implementing these into a class with methods which can be accessed from the from. In the main from I have a textbox called message textbox I …

Member Avatar for farad
0
1K
Member Avatar for JHus00

[CODE]//function example #include <iostream> #include <cmath> using namespace std; float cutoff(float& windchill) { int z; z = (int)(windchill + 0.5); return(z); } float calculate (int& t, int& v) { float windchill; windchill = 35.74 + (0.6215 * t) - 35.75 * pow(v,0.16) + 0.4275 * t * pow(v,0.16); return(windchill); } …

Member Avatar for HealBrains
0
113
Member Avatar for rockstar8577

I was wondering if its possible to specify the name of a file being created with a variable yet still specify the extension for the file. Example: [code] string name; cin >> name; ofstream myfile; myfile.open(name".sta", ios::out); [/code] i was wondering if you could do something of the sort i …

Member Avatar for rockstar8577
1
73
Member Avatar for daviddoria

I am trying to get some code I found online to compile. It looked like this: [code] #include <iostream> #include <list> using std::list; template <class T> class leda_list : public std::list<T> { private: iterator loopIter; [/code] the error was: ‘iterator’ does not name a type I tried changing it to: …

Member Avatar for daviddoria
0
273
Member Avatar for ge6a93

Hi, how can i transfer variable from one dialog class to another. For example i have int i = 10; in my first(global variable). How to obtain this value in the second class? I have int i1; How can i i1 get the value of i ? Thanks in advance!

0
56
Member Avatar for JHus00

I need to make this formula c++ compatible, ive spent quite a while trying to figure this out, looking for some help! WindChill = 35.74 + 0.6215T - 35.75(V^0.16) + 0.4275T(V^0.16) Thanks!

Member Avatar for JHus00
0
92
Member Avatar for sexyzebra19

I have a matrix A stored in column major order as 1 3 2 4 and I'm using this function to output it in row major order, i.e. 1 2 3 4 which is does correctly. However I'm confused about how it does this, as I thought the loops would …

Member Avatar for Dave Sinkula
0
146
Member Avatar for nuB

i am supposed to have 2 void functions and 4 value returning functions (including main) to eventually calculate netsalary from calling the specific functions to calculate tax and insurance and receive and display data.... basically i'm wondering what is my error (compiled in dev and couldn't figure out what was …

Member Avatar for nuB
0
192
Member Avatar for D4n1sD

Thats the code I am trying to do, what I try to do is a loop, that only breaks if the user press enter. any other ideas? [CODE] while(GetAsyncKeyState(VK_RETURN)==0) {}[/CODE]

0
69
Member Avatar for Cristofor

Hi, I am using Visual studio 2008 express edition now. It does not have stdafx.h. so I download stdafx.h and three other head files: AFXWIN.h, AFXEXT.h and AFXCMN.h from google. I put these four headfiles into C:\Program Files\Microsoft Visual Studio 9.0\VC\include. And then I wrote a small program just to …

Member Avatar for Dave Sinkula
0
190
Member Avatar for kirennian

Basically, this is what I'm trying to acheive in its simplest form. [IMG]http://img72.imageshack.us/i/dsgjgsfnhfn.jpg/[/IMG] Does anyone know how to change sin/cos in this way? I just require them to linearly increase/decrease over the set amount of time set on the x axis. In case of the link not working, these are …

Member Avatar for Salem
0
161
Member Avatar for ravenrider

hey guys its 1.30 am and I just can't see where the problem here ! the text file contains just brand , model and price, please help ! [CODE] #include<iostream> #include<fstream> using namespace std; struct computer{ char * brand ; char * model; double price; }; void readin(computer * , …

Member Avatar for Salem
0
129
Member Avatar for corby

ok so i need to allow the user to enter a number they want or delete that number from an array. Then i need to combine those arrays(union) and then find out which elements are common(intersection). only numbers 0-100 are allowed to be entered. so if an element is in …

Member Avatar for Salem
0
260
Member Avatar for PDLajus

Hello to every one, I am writing a simple web browser on c# 2008 express edition using WPF. It is working fine with www websites and display all content correctly. But if I want to open some local webpage - for instance "file://C:1/1.htm", it is save the webpage instead of …

Member Avatar for PDLajus
0
114
Member Avatar for rush52490

out teacher told us to make a timer. interfacing the timer circuit we've made and parallel connector and using c++ program to control the flow of the timer. we should able to control start, stop, and reset. my problem is the code for it and the connection of parallel connector …

Member Avatar for dmitry_n
0
70
Member Avatar for Asalearam

I am going to write a game with QT but i dont know how to start. Give me a tutorial for QT please.

Member Avatar for Stefano Mtangoo
0
542
Member Avatar for mmasny

Hi, I've made a class whose member is a reference to a dynamically created object. How should I code a destructor?

Member Avatar for mmasny
0
155
Member Avatar for Coder2009
Member Avatar for Stefano Mtangoo
0
112

The End.