48,985 Topics
| |
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. … | |
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 … | |
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 … | |
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 … | |
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. | |
[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 … | |
[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() … | |
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 … | |
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. … | |
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 :-| | |
i wanna start programming with c++ what would you guys suggest is the best compiler program out at the mo? :twisted: | |
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 … | |
[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> // … | |
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. … | |
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 … | |
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 … | |
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 … | |
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 … | |
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 … | |
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 | |
| 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 … |
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 … | |
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 … | |
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 … | |
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 … | |
| 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 … |
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 … | |
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 … | |
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; } | |
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 … |
The End.