49,761 Topics

Member Avatar for
Member Avatar for luftey

I'm currently on my final C++ project for the semester. My assignment is: =================================================== Programming Assignment 6 Attached Files File data.txt (0.628 KB) File sample_dynamic_array.rtf (33.957 KB) The attached text data file contains a list of numbers between 50 and 150. Create a program that reads those values into an …

Member Avatar for Schol-R-LEA
0
232
Member Avatar for iGuardian

[code]/* File: Rainfall.cpp Description: Write a program that reads in the average monthly rainfall for a city for each month of the year and then reads in the actual monthly rainfall for each of the previous 12 months. The program then prints out a nicely formnatted table showing the rainfall …

Member Avatar for iGuardian
0
1K
Member Avatar for jankeifer

guys, can you please suggest a 2 player game? any 2 player game as long as the difficulty of coding is at an intermediate level. thanks! :D hope for some replies soon.

Member Avatar for Sgt. Pepper
0
176
Member Avatar for Sphiros O'kelli

Hey!! I'm new to C++, this is the final program of my semester and I am stuck sooooo hard... I have the code laid out and it will compile but my functions wont work like I want them too. here is the code: [CODE] #include<iostream> using namespace std; void getlist(int[], …

Member Avatar for Sphiros O'kelli
0
316
Member Avatar for harde

The program should calculate the average of the values stored in the [B]rates[/B] array. It then should display the average rate on the screen. Display the average with two decimal places. Complete the program using the [B]for [/B]statement. Save and then run the program. Complete the program and also have …

Member Avatar for Schol-R-LEA
0
232
Member Avatar for Thermalnuke

Alright, I am trying to count words in a file. The user running the program can choose a file that the program can count how many words are in the file. I have it working, but.... it keeps looping the last sentence [CODE]cout<<"There are "<<words<<" words."<<endl;[/CODE] over and over and …

Member Avatar for Thermalnuke
0
165
Member Avatar for lrnzsmok1

i need to write a Selection Sort program using the following functions: Get data(), Smallest(), and Exchange(). The program should include pointers. The following data should be included in the output: 23, 78, 45, 8, 32, 56. SAMPLE OUTPUT: 23 78 45 8 32 56 8 78 45 23 32 …

Member Avatar for shubhamhaowa
0
210
Member Avatar for jacob501

Hi, I want to make a specific program and I was looking around the internet for some help. I came here but wasn't sure what section to post in...so I chose this one for now! What I want to do is make a program that uses the internet and retrieves …

Member Avatar for Warezov
0
210
Member Avatar for HASHMI007

[CODE]#include"stdafx.h" #include <iostream> #include <conio.h> using namespace std; class LinkList { protected: struct node { int exp; int info; struct node* next; }; typedef struct node * NODEPTR; NODEPTR listPtr; public: LinkList(){ listPtr=0; } int IsEmpty(); void PushPoly(int cof,int ex); //void Mult(list); void Add(LinkList Poly1 , LinkList Poly2); void Display(int …

Member Avatar for HASHMI007
0
186
Member Avatar for Dakot

hello, I have a problem.I want to search by color , gender (these are the options) in a text file (called text.txt). My text file looks like that. How can i do that?) ex. cin>>s , then find for "s" , if found cout all data about him (gender , …

Member Avatar for Schol-R-LEA
0
131
Member Avatar for stereomatching

I try some codes snippet from boost spirit, but it only incur a lot of error mesasges [code] #include<iostream> #include<string> #include<boost/spirit/include/qi.hpp> void spirit_01() { namespace qi = boost::spirit::qi; std::string input("1.0,2.0"); std::pair<double, double> p; qi::parse(input.begin(), input.end(), qi::double_ >> ",">>qi::double_, p); //#1 } [/code] After some struggle, I figured it out the …

0
74
Member Avatar for Thermalnuke

Alright, I am having a problem with an error message that comes up, i am pretty sure the code is alright, but it might be the code, i have tried re-installing VB (Visual Basic 2010). i have tried a few things on the web and nothing. here is the error …

Member Avatar for Thermalnuke
0
110
Member Avatar for vincent5487

[CODE]#include<iostream> using namespace std; void convertLetter(char); void convertWord(char); int main() { char input; do { cout << "Please make a selection\nS:\tConvert a single letter to its corresponding telephone digit\nW:\tConvert a word to its corresponding telephone number\nQ:\tExit" << endl; cin >> input; if (input == 's' || input == 'S') convertLetter(input); …

Member Avatar for vincent5487
0
235
Member Avatar for vincent5487

Write a program that generates 10 (TEN) random integer numbers that range from 1 to 50, and store them in an array variable. Display the original order of random integer numbers. Then create a function that sorts the number elements from the array in ascending order and display the result. …

Member Avatar for Fbody
0
435
Member Avatar for abhiagro

can someone please help me with this code? i am getting the following error : [Linker error] undefined reference to `enr(int, int, double, double, double)' thanks #include <iostream> #include <fstream> #include <math.h> #include <string> using namespace std; float ran1(long *); #define IA 16807 #define IM 2147483647 #define AM (1.0/IM) #define …

Member Avatar for Schol-R-LEA
0
265
Member Avatar for fmasroor

Hello. I am looking for a website that I can download Microsoft Visual c++ 6.0 or whatever it's called, the compiler. Just the compiler, nothing else like those things on Mic.'s website. Please give me a good up to date link that has a free full download for the compiler. …

Member Avatar for jwenting
0
308
Member Avatar for peachekeen

Hi everyone, I am a beginner with C++ and am trying to self teach myself the programming. I have been watching tutorials and reading about it and am still getting confused. if anyone can offer help with this exercise and help me to better understand whats being done and why. …

Member Avatar for metronomu
0
132
Member Avatar for metronomu

A question regarding inheritance implementation. Let's say we have 2 classes: [CODE]class B { public: int x; // for the sake of argument it's public, don't stone me }; class D: public B { public: int x; // again x, i know ... stupid dilemma };[/CODE] Now, if you will …

Member Avatar for metronomu
0
137
Member Avatar for astrolegacy

Hiii Buddies....I am having a very frustrating time trying to understand where to start from and where to end in creating online enrollment billing system....there is tonnes of stuffs that i have no clue wat to do.....since m a beginner it is possible to help me out with the coding …

Member Avatar for WaltP
0
247
Member Avatar for spicyrelish

I think my problem is that C++ cannot work with class instances without initializing them in a more explicit way than I am doing, but I'm not sure how to go about doing that.... maybe there's an easy solution but it isn't obvious to me. does someone see another approach …

Member Avatar for sfuo
0
167
Member Avatar for coolbeanbob

Is it possible to have multiple input streams open at the same time? I know it takes a lot of time to open a file, and I am trying to be as efficient as possible. I really need to have two streams open at the same time. The data is …

Member Avatar for coolbeanbob
0
246
Member Avatar for jeevsmyd

Overload new and delete operator to manipulate objects of Student class.Class Student must contain data members like char * name,int roll_no,int branch etc.The overloaded new and delete operator must allocate and deallocate memory for the student class object and its data members. Here is my code. The problem is that …

Member Avatar for jeevsmyd
0
407
Member Avatar for cafegeo

Hello all. This program is supposed to maintain inventory for 5 warehouses with 3 items each warehouse. Each in a different city. You can place an order or send a shipment to each warehouse. When you place an order, if one warehouse does not have enough of the item it …

Member Avatar for PrimePackster
0
155
Member Avatar for Jockster

The question is: Write the declarations for variables to hold a department code (which is a letter), hourly wage, number of dependents, last name, and a constant to hold the current FICA rate of 7.75%.

0
48
Member Avatar for kareem8

i want help from visual studio experts :) when i debug an opencv code in visual studio the following exception is appear as in picture : [URL="http://imageupload.org/?d=B810B9521"]http://imageupload.org/?d=B810B9521[/URL] can any one help me please :)

0
51
Member Avatar for Thermalnuke

Hi, there im a new member, I have a few questions. i am having a problem i am trying tp find words that are related together by one word for example "dous" Tremen[B]dous[/B],stupen[B]dous[/B] ect... I have my code working so that it goes through my text file and picks out …

Member Avatar for Thermalnuke
0
136
Member Avatar for Tokenfreak

I am trying to make an expression calculator and it works ok, but only for single digit numbers. I take in the expression in infix notation and then convert it to postfix notation. I just am not sure how to allow it calculate the correct answer with double digits. I …

Member Avatar for mikrosfoititis
0
2K
Member Avatar for lmytilin

[CODE] #include <iostream> #include <string> #include <cctype> #include <iomanip> #define N 36 using namespace std; string EraseWhiteSpaces(string &str_nospaces) { int i; for (int i=0;i<str_nospaces.length();i++) { if (str_nospaces[i]==' '||(str_nospaces[i]=='\t')) { str_nospaces.erase(i,1); i--; } } return str_nospaces; } string ConvertToLowerCase(string &str_lowercase) { int i; for (i=0;i<str_lowercase.length();i++) str_lowercase[i]=tolower(str_lowercase[i]); return str_lowercase; } void SortedFrequences(int …

Member Avatar for mikrosfoititis
0
189
Member Avatar for eblanco1

It is an assignment to create a drink machine simulator. I have a problem with number 3 sprite its not alined with the rest. And i would like to know how to add special characters to add borders around the menu and create a table. [CODE]#include <iostream> #include <string> #include …

Member Avatar for eblanco1
0
243
Member Avatar for HumanBeing86

// Linked list Hi... Below is the codes that I wrote so far... everything is fine but just abit headache on when trying to read the data from the file...and it give me a weird things... my output suppose is like this [CODE]============================================================== No Name/Site Location Weight 01 ThunderStone Russia …

Member Avatar for HumanBeing86
0
123

The End.