Beginners - May 2018 (Page 5)

error while overloading << operator
 
Hello, just getting started with classes. Have a Date class, using enumeration to define months. Then I overload operator << to print out date of "today" and ...
[3 replies] Last: Thank you for the help - it's working now! Implemented all the corre... (by Jenny89)
by RogerT
How to use destructor in my case
 
Below is my code, I want to know how to use destructor in my case and how to implement in my code. Thank you for helping. class SM { node* head; no...
[3 replies] Last: in words, it looks like you need to delete the entire linked list (no... (by jonnin)
Crasg
 
Hey guys, I hope you can help me. I wrote the following programm: //Main #include<iostream> #include "Bilddaten.h" using namespace std; int m...
[3 replies] Last: Thanks for your help. i really appreciate it (by Vitalik2)
While loop
 
So recently we just started learning while loop. Now I have a task to do (yes for homework) but I have the main idea how it works. Basically, I have n. An...
[1 reply] : pseudo-code: print n while n is greater than 0 set m to square r... (by icy1)
by CppPy
What is the output?
 
Suppose that num is an int and discard is a char. Assume the following input data:#34 What value (if any) is assigned to num and discard after each of the follo...
[2 replies] Last: Don't just dump your assignment. What is your question? And remember ... (by tpb)
Returning a smart pointer?
 
Trying to write a getter function (yes I know they shouldn't be used) and I'm trying to return an std::unique_ptr<Paddle>. I have 4 of these Paddle objects in t...
[7 replies] Last: @CGunn86, In the first post of the thread, it appears (edited since th... (by icy1)
Transposition cipher code not completely working (1,2)
 
Input into array O N E O F T H E E A R L I E S T K N O W N U S E S O F T R A N S P O S I T I O N C O D E S W A S D E S I G N E D B ...
[25 replies] Last: It seems icy1 is the only one who can shed light on OP's code... :-) (by Enoizat)
'expression' was not declared in this scope
 
Hi guys: I have a calculator program that I need to assemble. Ive got 3 dependent functions, they are called: 1.- expression. 2.- primary. 3.- term. I need to ...
[6 replies] Last: Thank you! It compiled. I decided to just instead of using that error ... (by Mustermann)
Which sorting algorithm would be best for a X set of integers?
 
I am wondering about which sorting algorithm would be most efficient for sorting: (Presuming they are integers) 1. An array with 10 elements that are unsort...
[3 replies] Last: Not really. Again, for 1&2, a really good quicksort will tie or bea... (by jonnin)
public to private values
 
Hi all: I need to change a public value from a class to private with a get method. I´ve tried it but I don´t know exactly what Im doing wrong. Here the stan...
[2 replies] Last: Here is what I have done in the header file: #ifndef TOKEN_H #define... (by jlb)
no match for 'operator<<' (operand types are 'std::basic_ostream<char>' and...
 
Hello: Does anyone know how to fix the code? It´s a calculator that uses different classes. Here is what the compiler says when I try to compile: no match for...
[8 replies] Last: This was my first topic and it is very disorganized so I will solve it... (by Mustermann)
by jplank
Problems with cin not picking up all strings?
 
I'm trying to write code that can get input from a user. The input will be something like "1 empty container" or "5 fish", etc. Basically a number followed by o...
[2 replies] Last: Hello All, As I have learned over time and the hard way Ganado's line... (by Handy Andy)
function definition and declaration
 
Hi all, I have a noob question: Why is the compiler able to locate a function definition in some xyz file if there is a declaration for it but not able to lo...
[9 replies] Last: in case we have f defined in the same file where we call it no need f... (by tpb)
by H00G0
Quick question
 
Hello, I have a quick question: Can you call a class function within the same class constructor? thanks!
[2 replies] Last: Thanks (by H00G0)
I need help installing the script. Can you help me?
 
I need help installing the script. Can you help me?
[1 reply] : Installing what script on what? (by H00G0)
Trying to make a program which turns first and final letter of each words to uppercase
 
As the title says, that's the program. Everything works fine until I enter more than one blank space. E.g. they are tall - works fine ; they are tall - retur...
[1 reply] : You are subtracting 32 from all characters that are next to a space. S... (by Peter87)
Functor question
 
hi guys from this tutorial https://www.cprogramming.com/tutorial/functors-function-objects-in-c++.html I don't understand how it works,I mean he is passing _...
[3 replies] Last: thanks tpb :) yeah that does look clearer and thanks Peter good spot ... (by adam2016)
by dq9
Why does my int function execute before my main function?
 
The function I am specifically talking about is: int showFight(variables); On line 104 and 172. And here is my full code: #include <iostream...
[9 replies] Last: Where am I calling showFight? On lines 113 and 129. how can I fix... (by keskiverto)
by zetef
Detecting comments in file input not working
 
so I have a program that reads from a file that looks like this: hello-world .txt hello, world! this is the content $stopf the first part ('hello-...
[1 reply] : This may not be exactly what you're looking for, but maybe it will giv... (by tpb)
Help me PDF file downloadGet GAME GOLF LIVE Data On Your Watch
 
Knowing more about your golf game may shave strokes off your score. Shortly, using a quick Glance at your watch, you'll see essential shot-tracking and space da...
[1 reply] : I'm sorry but you're asking that on a C++ forum? (by H00G0)
May 2018 Pages: 1... 34567... 19
  Archived months: [apr2018] [jun2018]

This is an archived page. To post a new message, go to the current page.