48,985 Topics

Member Avatar for
Member Avatar for Lapari

May anyone please help me with this: (I am new to c++) Create a [b]SavingsAccount[/b] class. Use a [b]static[/b] data member to contain the [b]annualInterestRate[/b] for each of the savers. Each member of the class contains a [b]private[/b] data member [b]savingsBalance[/b] indicating the amount the saver currently has on deposit. …

0
60
Member Avatar for acidburns

Hi everyone. My assignment is to take a line of text as input from a file and analyze it to give the following output . I ...identifier have....identifier 9....number apples...identifier. Anything like 2day will show that the string is wrong..I tried to write the program in simple c++ but unfortunately …

0
67
Member Avatar for raghavendrak

Hi I have installed Eclipse and I am trying to run C++ programs using the cdt tool which I installed it from the update manager present in the eclipse itself. But whenever I am trying to run a C++ program I am getting this error. Error starting process java.io.IOException: Exec_tty …

0
138
Member Avatar for baboon4000

hello, i need to hand this in this week, someone please help me :p I need to do the followings: 1) allows user to add a new property to the collection 2) allows user to remove a property from the collection 3) allows the status to be changed from for …

Member Avatar for baboon4000
0
192
Member Avatar for gurubis

pls help me in providing links to any tools or user guide which would help me to migrate from IBM C++ application using IBM open classes to Microsoft C++.Thanks in advance for your help.

0
40
Member Avatar for Acidburn

[php] #include <iostream> #include <cstring> using namespace std; class date { public: date(int = 1, int = 1, int = 1990); //constructor void Printdate(); void setday(int); void setmonth(int); void setyear(int); void setdate(int, int, int); private: int day, month, year; }; date::date(int d, int m, int y) { setdate(d,m,y); } void …

Member Avatar for Acidburn
0
445
Member Avatar for ch1ck3n

[CODE] #include <iostream> // required for input and output #include <fstream> #include <cstdlib> // required for rand() function using namespace std; // function prototypes void storeData(char cellArray[][18]); void printArray(char cellArray[][18]); int checkNeighbors(char cellArray[][18], int row, int col); void makeContagious(char cellArray[][18], int dayArray[][18], int row, int col, int neighbors); int main() …

0
67
Member Avatar for xplod420_2

Hello i am writing a program and i really need help. here is what the program is about. 1. It needs to ask a number of tickets sold. 2. persantage which goes to some other coast. This input will be entered in percent format. program must convert this to a …

Member Avatar for xplod420_2
0
140
Member Avatar for radioman28

Hi, I am writing a couples class, one base, and one derived to track an employees pay records. It has a static private ptr array to store Employee and EmployeePay objects. [CODE]static Employee* empArray[];[/CODE] Employee has first and last name, ssn, id number and a date. EmployeePay derives from Employee. …

0
142
Member Avatar for Tink2416

each time i put my Sims cd in my disk drive this message always comes up: Microsoft Visual C++ Runtime library Runtime error! program c:\Program Files\Maxis\The Sims\Sims.exe Abnormal program termination I have a windows 98! Do you have any ideas to fix this problem? Please help me :-|

Member Avatar for Dave Sinkula
0
109
Member Avatar for tommy1988

i wanna start programming with c++ what would you guys suggest is the best compiler program out at the mo? :twisted:

Member Avatar for Raven11
1
114
Member Avatar for tw0nk

Hi I am getting this error with my code as I try to pass a 2d array into a function : mymain.cpp:173: error: cannot convert `float (*)[((dimensions - 1) + 1)]' to `float**' for argument `1' to `float objfunc(float**)'])' The code is as follows: [url]http://cpp.sourceforge.net/?show=4356[/url] The lines 0030, 173 and …

Member Avatar for Narue
0
82
Member Avatar for sinB

[SIZE=2][B]TO CALL OTHER PROGRAMS FROM WITHIN OTHER PROGRAMS-[/B][/SIZE] Just include the standard c header file cstdlib (no .h!!). You can now use the function system( :eek: ). It takes only one parameter- the name of the program you want to call! Here is an example [CODE]#include <iostream> #include <cstdlib> // …

Member Avatar for aj.wh.ca
0
180
Member Avatar for DaveSS

i got the program to work without any errors before i started to try to get the sort function to work in the [B]main[/B]. function. I need to get the function call for the [B]sortIndex.cpp [/B] to work so i can sort the user output by descending order of profit. …

Member Avatar for Dave Sinkula
0
171
Member Avatar for blackdove

I'm not finished with my program yet, but i've run into a few problems. The first main problem i see is that i seem to be doing something wrong to display the array that the user enters. It only shows one value, and it displays it twice. I cant check …

Member Avatar for blackdove
1
147
Member Avatar for sinB

Hi, If any of you know JavaScript, you will know about the split() member function of a string. In it's simplest form, it splits the string that you call it from by the char argument and returns an array. I found this very useful, so I tried to write it …

Member Avatar for Fasola
-1
307
Member Avatar for purplefantasy

The Acme Software Company sells its "Adding Tutor" software for $109.Quantity discount are given using the following table: Quantity Discount 10-19 20% 20-49 30% 50-99 40% 100 or more 50% Write a program that asks for the number of units sold and calculates the total cost of the purchase including …

Member Avatar for alc6379
1
183
Member Avatar for sgbartley

I am new to C++ and have problem that isn't adequately addressed in books and online. Say have have a program doing salaries. In this program all inputs should be numeric. If they aren't the program won't execute properly and you will never know it. Using the cin.clear and the …

Member Avatar for Narue
0
178
Member Avatar for dv916

I am having a problem with C++ templates which is actually quite embarrassing for me to admit to since I predict a lot of you will figure my problem out faster than it took me to write this post but I've exhausted my patience for right now. I wrote this …

Member Avatar for Narue
1
932
Member Avatar for cbsamuels

I want to get the x y coordinate of the cursor on an image. CursorPos is included in the help files but not how to use it. Borland C++ Builder5. Can anyone help me? Thanks Chuck

Member Avatar for 1o0oBhP
0
96
Member Avatar for j.kelly

I'm pretty new to C++ and I'm having a problem with a Uni coursework. I have two classes A & B which need to be able to call each others functions so they each hold a pointer to the other. I had the problem that they #included each other so …

Member Avatar for 1o0oBhP
1
99
Member Avatar for Asif_NSU

I want to make a program that will start off by opening a text file(blank). The user will put an expression in the file and as he hits the enter(enters a newline character) the result will be shown in the next line of the same open file. Itz almost like …

Member Avatar for Narue
1
255
Member Avatar for ok555

Ok, im new to c++ and i looked around and couldn't find anything on it.. I have a global char such as the one below, i made a loop to go through and basically "grab" each name in the names list and then display it to me.. but instead of …

Member Avatar for ok555
1
159
Member Avatar for jayrads

I'm writing a c++ program for a class I'm taking. I'm having a problem getting the string variable into the void print_results function. Basically, at the beginning of the main function, I ask the user for their name. I can use the name variable in the main function and it …

Member Avatar for jayrads
1
193
Member Avatar for Tetsu

Hi this is tetsu here I need a little help regarding input and output. I am trying to write a program to read information from a text file as long as there is names and numbers next to them (test score numbers). For each name read, a sequence of test …

Member Avatar for Tetsu
0
182
Member Avatar for j.kelly

Can somebody please tell me where I should put an enumeration which will be used by several classes. [code]enum Direction { UP = 1, DOWN = 2, NONE = 3 };[/code] All of the classes have their own .h and .cpp files and at the moment I have the enumeration …

Member Avatar for j.kelly
0
79
Member Avatar for evilsilver

ok i am a new programmer and am running in windows xp and 98 and am using the borland c++ builder 3, I am trying to make a window that will simply ask the user to input a string (called pathname) and store it to another file for use in …

Member Avatar for Tight_Coder_Ex
0
218
Member Avatar for dal4488

I'm have a really hard time with this program and am totally lost. I'm trying to write a program that reads a set of integers and then finds the sum of the even and odd integers. So far this is all I have come up with, but I'm sure it's …

Member Avatar for dal4488
0
170
Member Avatar for arikeri

consider this [CODE] vector<int> :: iterator it; int i; vector<int> A; for (i=0; i<5; i++){ A.push_back(i); } for(it = A.begin(); it != A.end(); it++){ cout<<*it; }[/CODE] vector<int> :: iterator it; int i; vector<int> A; for (i=0; i<5; i++){ A.push_back(i); } for(it = A.begin(); it != A.end(); it++){ cout<<*it; }

Member Avatar for Narue
0
72
Member Avatar for arikeri

Hi, I want to declare a function, which takes input of a set of integers and returns a set of set of integers , I tried this but, it ain't correct , plz tell how I should do what I want [CODE]#include<iostream> #include<set> #include<string> using namespace std; int Q; int …

Member Avatar for Dave Sinkula
0
226

The End.