48,983 Topics

Member Avatar for
Member Avatar for sweetbaby

hi, all. i have some problems to do array. i am supposed to get the average and sum in given number of array. but, i only got 1 in my all answers. please, tell me what was wrong in my program. thank you. //hw for array #include <iostream> #include <iomanip> …

Member Avatar for jasweb2002
-1
113
Member Avatar for old lady

I'm told you are never to old to learn something new but right now I don't believe that. I thought I understood this but the program I wrote just doesn't work any suggestions? Write a program that asks the user to enter the price of an item and the sales …

Member Avatar for Coach_Nate
-1
107
Member Avatar for Marauder

Greetings, I have my first assignment for my programming class to do, but first, I will say that I am aware of those people who post entire problems requesting members to do their homework for them. This is not really what my post is about. I'm having a little problem …

Member Avatar for Marauder
0
235
Member Avatar for ze_viru$

hi guys, I want to create a class called DoubleSubScriptedArray.this array should be able to take maybe a 3 by 5 array or 1 by 3.My program is giving me a problem when i try to overload the stream-insertion and stream-extraction operator.Below is my program pliz help me to get …

Member Avatar for Narue
-1
224
Member Avatar for hopeolicious

[code]#include<iostream.h> #include<stdlib.h> const int MAXCHARS = 500; char st_line[MAXCHARS]; char ch_option; int i_va; int i_ve; int i_vi; int i_vo; int i_vu; int i_word; int i_count = 1; int i_number = 0; int i_vowel = 0; char ch_char; void getdata(); void vowels(); void words(); void putdata(); int main() { do{ getdata(); …

Member Avatar for hopeolicious
0
96
Member Avatar for kerrigan88

Alright, mine's a long one. The error I keep on getting is bin_search local funtion defs are illegal. Think there is something worng with my binary search. Anyone see what's worng with it? I'm sapose to have it display 1. The number of searches completed 2. The number of successful …

Member Avatar for Narue
-1
118
Member Avatar for hopeolicious

Can someone give me a start of my program I have to write a program usig functions that will read in an array of text and using the case statement determine the number of capital and lowercase letters(a, e, i, o, and u's) found in a string of text with …

Member Avatar for Chainsaw
-1
120
Member Avatar for BlackPhoenixVII

i can not figure out a way to let the user save their own file name in the ofstream i tried to do this... string SaveName; std:: ifstream input("finale.txt"); std:: ofstream output(SaveName); and then a prompt asking user for SaveName i know this doesn't work but i dont know what …

Member Avatar for BlackPhoenixVII
0
74
Member Avatar for lost_c++_dude

I've tried everything but this program won't run. If I plug in numbers for length, width, and depth it won't tell me the cost to resurface. Any suggestions? //prb01-1.cpp //This program calculates the total surface area of a pool and the cost to resurface it #include <iostream.h> #include<iomanip.h> //using namespace …

Member Avatar for alc6379
-1
131
Member Avatar for wangstarr

Hi, I am stuck and my head is spinning with this project that I am working on for my beginners c++ class. Can someone show me how to work this? Here is the problem: Write a function that uses an array parameter to accept a string as its argument. It …

Member Avatar for Narue
-1
2K
Member Avatar for Rasmo

Hi all, I'm a total beginner at C++, and I'm planning on trying out by writing a small, text-based game with a command line. The game has different areas which are described in pure text, and I guess a good solution to put all the pure data (descriptions and so …

Member Avatar for Xnoudas
0
113
Member Avatar for epsos

hi everyone i have been using ict for about 6 years now and want to learncomputing e.g programming and was wondering where to start becaause people post codes and i have no idea what they are on with and was wondering if there is any good sites where u can …

Member Avatar for epsos
0
183
Member Avatar for phr0stbyt3

im working on a program that generates a random number and asks the user to guess what it is. right now im stuck on checking to see if the number is between 1-20. how would i make it continuously loop back until the user enters a number between 1-20? the …

Member Avatar for phr0stbyt3
0
172
Member Avatar for darksea_99

I am looking into trying to buiild an onscreen display model based on field data to look at the factors that control the feeding and foraging of the northeern right whale - some have suggested that i use C++ and others Visual Basic. I need some help. The work would …

0
89
Member Avatar for jasweb2002

Hey everyone, I just started writing this program when I hit a problem with the destructor. Me and my buddies in the lab could not figure out what is going on. The error said something about symbol referencing error and refers to the destructor. The program is set in three …

Member Avatar for jasweb2002
-1
77
Member Avatar for toadie2004

this is my assignment 1) Write a C++ program to calculate the average test scores for 10 students. The test scores are stored in a file named 'scores.dat'. The average along with the test scores should be written to an output file named 'results.txt'. The input file 'scores.dat' contains three …

Member Avatar for Narue
-1
127
Member Avatar for smarkles

Hello, I'm doing a project for C++ using OPengl. I have the Super Bible and tried doing just the "simple program". I'm getting a l inking error. I used Win32 Console. Opengl is already installed, so I just downloaded Nate Robins glut llibrary and installed it as directed. What am …

0
102
Member Avatar for skamen

Hi, I'm working an a project that must take a text file (provided to us, in.txt) that has the scores of students from different sections on different labs. You can view the assignment page at: [url]http://www.cs.wmich.edu/~nelson/CS111FALL04/lab06/index.htm[/url]. The problem I'm having is that I can't think of how to make a …

Member Avatar for skamen
0
131
Member Avatar for bryan7890

program that asks user to input 12 numbers of any type or domain (i.e. positive or negative) and record user's responce into an array. Process the input by manipulating it so that the numbers are arranged in the array in an ascending order (e.g. -1.2, -1, 0, 3, 4, 4.05, …

Member Avatar for bryan7890
-1
110
Member Avatar for Tresa

hai can anyone please help me find the error in my program? when i try to compile it says case bypasses initialisation of local variable. i can't figure out the mistake. i am sitting with this for a week. i will be thankful if someone could help me figure it …

Member Avatar for alc6379
-1
82
Member Avatar for hill0ster

[QUOTE]I am having two problems with this code. #1) The user is to enter a three digit number for their employee ID. No problem there. But if the user enters a negative number, such as -1 the program is to end and display the total payroll for the month, total …

Member Avatar for alc6379
0
138
Member Avatar for kazmoney

All right, I have an assignment for this introductory C++ class, and I'm sorry if this sounds silly, but I really don't know where to begin. We've just now gotten through the different kinds of loops and nested loops and that sort of thing, and my assignment is to write …

Member Avatar for Narue
0
125
Member Avatar for Asif_NSU

I have to insert a node in a binary search tree. This is what i wrote for the InsertNode() method. But it keeps producing segmentation fault when i run the program. I couldnot find anything wrong in the code. The constructor for TreeNode(int x) sets the item to x, leftchild …

Member Avatar for Asif_NSU
0
80
Member Avatar for knucklehead

I'm having trouble with a program to calculate a triangles area using fstream. The problem is I need the program to open the function to calculate the area in a file ("project3_1.dat") and to read in another file with coordinates of triangles. I wrote what I could in my program …

Member Avatar for Narue
-1
143
Member Avatar for Tresa

hai can anyone please tell me whether it is possible to make graphics work in borland c++? thanks Tresa

Member Avatar for Narue
0
116
Member Avatar for N3wbi3C0d3r

I learn faster when i have a motive to learn. Well if i have a project that uses all of the tutorial i use, i will be motivated to read sections and use it and make a full on project. I use [url]http://www.cplusplus.com/doc/tutorial/[/url]. If anyone can conjure up a HUGE …

Member Avatar for N3wbi3C0d3r
0
134
Member Avatar for hill0ster

[QUOTE]I am having two problems with this code. #1) The user is to enter a three digit number for their employee ID. No problem there. But if the user enters a negative number, such as -1 the program is to end and display the total payroll for the month, total …

Member Avatar for Chainsaw
0
89
Member Avatar for JoBe

Hi, I just wanted to ask if someone could give me a name of a good book in wich the mathematical formulas are written down with some explanation about them :?: Reason I ask is, I'm going to evening school to learn C++ but in using C++ I encounter very …

Member Avatar for JoBe
0
389
Member Avatar for dcving

Everything works well, but I couldn't figure out how to use the else statement in case the user inputs 0 as a number..any comments/suggestions? [code] /* Program description: Create a program that prompts for two integer values. The program will display whether the integers are either: - and +, + …

Member Avatar for Narue
-1
112
Member Avatar for boujibabe

I am a student with an assignment to wirite a program that makes change but i am not getting the correct output what am i doing wrong? [code] #include <iostream> using namespace std; //function prototypes int change1(float); int change2(float,float); int change3(float,float); int change4(float,float); int main() { //declare variables float Purchase=0.0; …

Member Avatar for Chainsaw
-1
85

The End.