49,761 Topics
| |
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 … | |
[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 … | |
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. | |
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[], … | |
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 … | |
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 … | |
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 … | |
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 … | |
| [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 … |
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 , … | |
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 … | |
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 … | |
[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); … | |
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. … | |
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 … | |
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. … | |
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. … | |
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 … | |
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 … | |
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 … | |
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 … | |
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 … | |
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 … | |
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%. | |
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 :) | |
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 … | |
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 … | |
[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 … | |
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 … | |
// 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 … |
The End.