Beginners - February 2020 (Page 7)

how do I determine the type when auto was used
 
In the example code below auto was used I want to know the type to replace auto in this code. typeid...
[7 replies] Last: Thank you, Ganado. (by Enoizat)
Beginner: Switch statement
 
Can someone help me fix my switch statement #include <iostream> #include <string> usi...
[5 replies] Last: Hello cblack618, You are welcome. Now that you understand that bette... (by Handy Andy)
Is My Class To Bloated
 
Hi everyone, another Rubber-Ducky gut-check question from me. I am learning about Enums and I ...
[5 replies] Last: Hi all, thank you both for those insights and points of best practic... (by ExponentialP)
by Kiryu
Template specialisation implementation
 
Currently I am struggling to compile the following snippet: Header: #ifndef TEST_H #define TEST...
[4 replies] Last: Except for the typedef, which is of course not visible from outside yo... (by Enoizat)
How can I get filenames in directory?
 
What I want is to get the list of filenames in a directory. I'm using windows. Apparently system(...
[3 replies] Last: Thanks a lot Handy Andy. (by Rakib771)
by deputy
class/composition
 
Hey!! How can i add price from Computer class with Monitor class price and calculate it in Complect...
[2 replies] Last: Thank you, it did help. (by deputy)
password restrictions homework
 
I am trying to figure out why the website that i have to submit my homework in won't accept this cod...
[5 replies] Last: wow, you were exactly right. The grading system was case sensitive. I ... (by zzzbluebb)
Need help with this class problem
 
I'm very new to computer science. My teacher gave us an assignment to greet someone, ask for their a...
[3 replies] Last: Hello Joni852, Looking at your code I misunderstood the instructions.... (by Handy Andy)
Need help with input validation
 
I am trying to modify it so when i enter a integer with a letter like 202o it gives me an error mess...
[3 replies] Last: This function parse_number yields a double if and only if the argu... (by mbozzi)
by AJ24
If else statements problems
 
Pre-written C++ program that computes the largest and smallest of three integer values. The three va...
[2 replies] Last: if(num1 > num2 && num1 > num3){ largest = num1; } if(num2 > num1 &&... (by AJ24)
by Mugaru
Help
 
Hi there :-)! New to C++ and got a question. I guess it is really simple but i am looking arou...
[3 replies] Last: oh, it can. you may need to make the OS think your program is a debug... (by jonnin)
Skipping functions
 
So i have to do a school project.. i need to create a program that calculates BMI and does other stu...
[2 replies] Last: Function_C and function_D both define local variable peso and use it w... (by dhayden)
BEGINNER: Virtual function and polymorphic (1,2)
 
Can someone give me tips and pointers about how i should approach this assignment and steps I need t...
[23 replies] Last: If I were just learning C++ as leisure your recommendation would be v... (by mbozzi)
Payroll Program Debugging
 
Hi, I'm working on a payroll program that uses OOP features. I'm aiming to read employee data fro...
[2 replies] Last: Make file: # CMAKE generated file: DO NOT EDIT! # Generated by "... (by beulette)
Question about reading text files (1,2)
 
If a text file contains only 2 lines, is it possible to read each line into an array of characters s...
[20 replies] Last: #include <iostream> #include <fstream> #include <string> using names... (by againtry)
error use of deleted function - when pushing back a class with a vector<unique_ptr<base>> member
 
Disclaimer; I realize some users are against "using namespace std;" and I don't use it in my actual ...
[4 replies] Last: Unique_ptrs do not have a copy constructor. They cannot be copied, onl... (by TheToaster)
by momof4
How to simulate gravity with multiple thrusts
 
I need a bit of logic help here. I'm working with a program to simulate gravity. the equation for gr...
[2 replies] Last: be careful. velocity vectors are what you need, not just velocity as... (by jonnin)
Simple classe question
 
Hi I'm new in c++ I create a class Shapes and child class Rectangle and Cercle. I want to be able...
[3 replies] Last: Wow thank you for your help. Without your help I'll never figure it o... (by vbourbeau)
input and output file
 
I wanna to write results of some calculation into a text file and then at the end, read them from te...
[1 reply] : The problem is that you cannot read from an output stream (ofstrea... (by Duthomhas)
Problems with bad_weak_ptr, shared_from_this and constructors
 
A while ago I wrote this post: http://www.cplusplus.com/forum/general/265809/ And then because o...
[1 reply] : I'm familiar with the algorithm. However, as is the case with most ... (by mbozzi)
February 2020 Pages: 1... 56789... 13
  Archived months: [jan2020] [mar2020]

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