- Strength to Increase Rep
- +4
- Strength to Decrease Rep
- -1
- Upvotes Received
- 1
- Posts with Upvotes
- 1
- Upvoting Members
- 1
- Downvotes Received
- 2
- Posts with Downvotes
- 1
- Downvoting Members
- 2
This is seg faulting whenever I try to remove anything. I've been trying to fix it for hours, to no avail. Any ideas? [CODE]#ifndef BST_H_ #define BST_H_ #include <stdexcept> #include <iostream> #include "btnode.h" using namespace std; /* A class to represent a templated binary search tree. */ template <typename T> … | |
allPlaylists is a vector of type Playlist. listSongs is a vector of type *Songs. [code] //Loop that goes through each element in the playlist vector. for(int k = 0; k < allPlaylists.size(); k++) { // loop that goes through each song within the Playlist vector element. listSongs is a vector … | |
Until now, I've coded in Notepad++ and compiled/tested in my university Unix account. This is getting tedious and inefficient, though. So, what can I do about it? Notepad++ doesn't have a compiler or debugger. I was thinking about using Eclipse. Would that be a good, free option? Does it have … | |
I've worked on it for a few days. It works great when I comment out the erase function. But it doesn't work when I include the erase function, which I use to remove an element in the playlist vector of type Songs. Here's the else if statement. The problem is … | |
Hey guys. I need to write a program that does the following: Requirements - The program... - Shall allow user to enter individual songs with information: - Shall ask for song name. - Shall ask for length. - Shall ask for artist name. - Shall ask for album name. - … | |
I know C++, but want to be able to code web sites, web applications, and maybe iPhone apps. I've heard that PHP and ruby on rails are good to learn. I also know there is an iPhone app language/SDK I could get my hands on. What languages and in what … | |
What does "->" do for vectors? And, how do you use the vector algorithms? And, also, when/why do you use #ifndef something_H, #define something_H, ..., #endif? Is there a difference between "vector" and "apvector"? | |
Today was my first time trying composition. It's for a lab project due Friday, and I have a lot of tomorrow to work on it. However, up until we have just been using one class per program. Now, my teacher wants us to use composition and arrays, despite only lecturing … | |
I've been working on a piece of code for a while, and it works as it is intended to. Now, though, I'm trying to the code down so that there is one main functions and every "action" is a function that is called. But, I have very little experience with … | |
I need to compute the number of nonnegative numbers from an input file. Everything works fine (for good input files and bad input files) except when there is a no data file (with nothing in it). Then, the number of nonneg numbers reads 1, even though it should be 0. … | |
Do any of you have aim or google talk or email that I could ask some C++ questions through? | |
New Question. I end the output to one file (fout1) and try to start it to a new input and output file, using this code: [CODE]" fout1.close(); } cout << endl << "Detailed employee reports have been printed in " << fileOutput1 << "." << endl << endl; cout << … | |
Here is my code: [ICODE]#include <iostream> #include <string> #include <iomanip> #include <cmath> using namespace std; int main() { const double e = 2.71828; double t, f, n, B, VoltageGain; cout << "Please enter the time in hours the culture has been refrigerated: "; cin >> t; cout << endl; while … |