I've read over the chapters where the topics of covered and am still left with a couple questions. If you guys wouldn't mind setting me straight, I'd appreciate it.
What 3 things happens when this...
Type: Posts; User: LearnOnTheFly
I've read over the chapters where the topics of covered and am still left with a couple questions. If you guys wouldn't mind setting me straight, I'd appreciate it.
What 3 things happens when this...
Wow that simple, I over complicated things in my head I guess.
I went ahead and used my construtor that declares a serial number only for the user and then asked for the info. But thanks all for...
Updated calls
operator << (cout, Saver4);
Saver4 += 1000;
operator << (cout, Saver4);
Saver4 -= 1000;
Whiteflags, I get what you're saying now it just took a minute to resonate. I actually have the arithmetic operators working correctly as well.
As my code is currently constructed and how I...
Phantom,
The project has been filled out by me. Although this site did help with the debugging along with my professor. He assigned for us to not change code we had previously but add in the...
Ah, I fixed the problem with none of the other object's running their task by declaring Saver4 after 3 and running through the task that way.
Saver4 only shows "John Claude 3250" once and does not...
The program worked fine before implemeting operator overloading, demonstrated in objects #1-3.
The goal is to add 4 overloaded operators as following:
>>read new name and balance from keyboard...
Main
#include <iostream>
#include <iomanip>
#include <fstream>
#include "SavingsAccount.h"
using namespace std;
No error, just no output
Ah thanks I missed that. I'm struggling to get my destructor to work. It should let the user know the object no longer exists.
header file
//destructor
~SavingsAccount();
Alright I had everything working until I started to incorporate my interst rate I'll post my header and cpp to see if anyone can steer me straight.
This is the error and I've tried tinkering quite...
Ok, I have my boolean function working in print but when I set new values to object 1 from no parameters to length = 5.4 and width = 10.5 it says its still a square
int
main()
{
...
Got it. Sorry, it's taken a bit for object-oriented to soak in. Is there anyway to declare the object name in the print function. I know I can use a cout in main with each object name before calling...
Ok, thanks iMalc.
I'm still struggling to solve how redefine objects. I have the five in man and then print their values. How can I set new parameters to the 2 of the objects after displaying the...
I have my 5 objects and I should print the length, width, area, and perimeter. Then I should set new parameter to object one and four and then print their values.
And to the black window comment,...
I tried your solution to no avail Elsyia. The output window come up but with no output. I receive this at the bottom when I try to debug:
'Project1.exe': Loaded 'C:\Windows\SysWOW64\ntdll.dll',...
Thanks white flags, I had never heard that saying but it will definately stick. I have my code compilng with no error but it shows no output when I debug. I don't know if it is my compiler or my code...
It is my last section of code that doesnt want to copy properly but here is the updated.
I'm not sure what you mean by invisible newlines either.
I notice you print the perimeter in main but I...
Oh silly mistake on the print function. I tried to copy my code to notepad then here but with the same issues so I'll keep tinkering.
My area and perimeter still come up unidentified, do I have to...
My indentations don't look like that in my compiler, it copied funny I don't know why.
My print function in my .cpp says the length,width, area, and perimeter are undeclared, are the statements...
I actually had my #includes typed properly, I don't know why it did that. I'm guessing you answered my question but I'm going to ask it more specifically.
In my header file I declare my 2nd...
Hi all, I'm new to C++ and have jumped right into object-oriented. Some of the concepts and syntax have me confused like no other. If anyone could take a look at the code an offer pointers/guidane it...
I need to make a command line program that accepts a word. Then uses a linked lists to store the characters and process how many occurrences of each letter is used.
I'm having trouble getting...
Wow. Thank you I overlooked that.
So I ran my program and I received the wrong average. So I printed the sum from my for loop and received a number 101520 after entering the parameters 5 10 15.
...
....