General C++ Programming - May 2016 (Page 15)

Homework Help
Hey guys, I need your help. I am working on homework and I am getting the error: undefined reference to 'letterGrades'(double)'. I do not know what it means and...
May 5, 2016 at 4:00am
[1 reply] : Nevermind, I figured it out. I forgot to finish the prototype. (by Ateimoortagh)
Opening file issues
my file is failing to open i have a file named numbers.txt with 12 numbers in it like so : 1 2 3 4 5 . . . through to 12 but it will not open can someone tel...
May 5, 2016 at 12:47am
[17 replies] Last: Thanks for that! (by Little Captain)
HomeWork prompt
Hello! I am basically having trouble on a homework prompt and need a little help with scenarios that break my code. Basically the prompt is that there is a sle...
May 4, 2016 at 7:01pm
[no replies]
Binary 7
Okay. So I'm trying to interface to a system and the interface document has the message definition layed out pretty nice. There is one field in the data struc...
May 4, 2016 at 1:15pm
[3 replies] Last: Should it be of the same type, char? A byte is a byte is a byte. S... (by MikeyBoy)
pretty much confused...about this
one of students wants to get output as upper right and upper left elements of matrix /* Declaration Of Header Files */ # include <iostream.h> # include ...
May 4, 2016 at 6:28am
[1 reply] : one of students wants to get output as upper right and upper left ele... (by keskiverto)
Double dispatch
I'm making a binary tree as well as various different classes that act upon it, with the idea being that the tree itself would be separated from the actions tha...
May 4, 2016 at 5:59am
[4 replies] Last: The reason I've been trying to do this, is that I've been trying to mo... (by shadowmouse)
I'd like a critique of my mathematical vector struct
I wrote a struct with operator overloading as practice, I want to know what I've done wrong and how I can make it better. Edit: would this thread be better sui...
May 4, 2016 at 4:09am
[5 replies] Last: hi, With radian_angle_between , are you aware that the dot product e... (by TheIdeasMan)
Can't figure out why num variable wont work
#include <iostream> #include <stdio.h> #include <stdlib.h> #include <math.h> #include <string.h> using namespace std; int main() { int num,i,j,k,sma...
May 4, 2016 at 1:55am
[no replies]
Error cannot convert Movies* to Movie* in assignment
In Movies.cpp at the bottom of the Movies* createMovies() function //////////////////////////////////////////////////////////////////// //Movie.h #ifn...
May 3, 2016 at 11:29pm
[3 replies] Last: You know, this is the exact problem constructors were created to solve... (by tipaye)
Compiler Error when creating a program about classes
I am trying to compile this program I created but I keep receiving compiler errors and I don't understand how to fix them. I created a Class called MyClass, i...
May 3, 2016 at 1:25pm
[6 replies] Last: In you Factorial function you haven't used braces around num = num * ... (by AbstractionAnon)
Store the contents of text file into map container and print contents of map
Hi everyone I am trying to store the elements of text file in map container. The elements of text file are not fixed number. I write this code to do this task...
May 3, 2016 at 10:50am
[1 reply] : Double post: http://www.cplusplus.com/forum/beginner/190328/ (by MrHutch)
parameter problem
so I making a linear sorting into a function and for some reason there is an error (Argument of type"int" is incompatible with type int) so here is my code: no...
May 3, 2016 at 10:27am
[3 replies] Last: still don't get how to make the code block thing http://www.cplusplu... (by MikeyBoy)
MD5 Hashing
I'm working on implementing the MD5 hash. I basically just took the pseudocode from wikipedia (https://en.wikipedia.org/wiki/MD5) and converted it to C++. I don...
May 3, 2016 at 12:36am
[no replies]
Binary search tree: Question about recursion vs. loops
For one of my classes, I have to create a binary search tree and search through it to find a certain number, however, I'm having a little bit of an issue unders...
May 2, 2016 at 11:40pm
[2 replies] Last: > the time it takes to find the number is less than 1 second computers... (by ne555)
Help Defining a class
This is the exact problem i was giving no context. I was reading my textbook and it was suppose to teach me how to use classes. I have no idea what to do, it wa...
May 2, 2016 at 9:58pm
[3 replies] Last: That's a really bad way to program. Eventually, you'll get something t... (by Moschops)
Read specific column in a line of text file
Hi everyone, I have text file like this: 516457 +9989704016796.0 1 516471 +9989844018787.0 1 516481 +9989984013367.0 1 516484 +9990124023453.0 ...
May 2, 2016 at 9:30pm
[2 replies] Last: Thanks for your reply Yep, I changed the type into double_t and it is ... (by ajlahmed)
Trouble with array of pointers
I am trying to make a banking program that reads commands from a text file and processes them. These are the commands: Create account amount Deposit accoun...
May 2, 2016 at 9:07pm
[no replies]
Segmentation fault when reading into hash table
So I am to take this code for a hash table from a book and I am to read in the contents of a dictionary and store them in this hash table. I can't figure out ho...
May 2, 2016 at 8:38pm
[4 replies] Last: A string literal like "One" is a const char* You are passing a co... (by ne555)
Logic error in my program. Member function containing string not valid?
#include <iostream> #include <cmath> #include <cstring> using namespace std; class MyClass { private: int num = 0; std::string description = 0; public: MyClas...
May 2, 2016 at 8:20pm
[4 replies] Last: I received a compiler error 'MyClass::description' should be initiali... (by Moschops)
by Xriuk
Protected member call from parent class should not be allowed
I have this situation: class Class1{ public: void someFunc(); // This is virtual too in my code, but I don't know if that matters } class Class2 : pub...
May 2, 2016 at 8:11pm
[2 replies] Last: @AbstractionAnon So, even if it's virtual it's the same? Ok, my only o... (by Xriuk)
May 2016 Pages: 1... 1314151617
  Archived months: [apr2016] [jun2016]

This is an archived page. To post a new message, go to the current page.
Registered users can post in this forum.