Beginners - February 2018 (Page 21)

by mrioz
How to remember Variables?
 
Hello! I am trying to make a stock simulator, but I want to make the portfolio remember its money, or value, it has. Thank you in advance for whoever helps me! ...
[1 reply] : variables retain their value until the program ends. if you want to r... (by jonnin)
using namespace std
 
I know it's bad practice to do using namespace std; If this is the case, why do so many universities and beginner level courses declare this statement so man...
[5 replies] Last: [quote=fiji885]Wouldn't it be better to just introduce students to som... (by TheIdeasMan)
Clock code assignment
 
I am told to write a program for a clock that has the user input a time with AM or PM and the user will then input an integer value to move the clock forward x ...
[2 replies] Last: thanks for looking at this eyesore! I fixed it out of principal on the... (by loumarlin1)
Getting my code to print out the sequential section
 
I am trying to print out the sequential part of my code. It is not working. Nothing is printing. my.class.h #ifndef MYCLASS_H #define MYCLASS_H #inc...
[1 reply] : bool operator!=(const Iterator& other) const { return false; } fo... (by ne555)
Help with an array comparison program
 
I'm writing this program for my computer science class and thought I had it figured out for the most part, but I'm getting questions saying they're incorrect wh...
[2 replies] Last: Nevermind I have figured out the program. Here it is fixed and working... (by CoderParzival)
HELP WITH LINKED LIST CODE
 
I'm trying to make this code work.The program compiles but I get this error:"Bus error: 10" after I select option 1. It's a linked list containing type Person s...
[3 replies] Last: Duplicate: http://www.cplusplus.com/forum/unices/230162/ (by TheIdeasMan)
system("pause") not owrking (visual Studio)
 
when i do below #include<iostream> using namespace std; int main() { cout << "hello"<< endl; system("pause"); return 0; } i get "h...
[8 replies] Last: In VS it should suffice to press Alt + F7, open the 'Linker'-Tab, Se... (by Misenna)
[Error] no match for 'operator>>'
 
This is my header file. Im trying to overload the istream operator and use ifstream in my main function to read in a text file with structured data (rows and co...
[2 replies] Last: Hello tidematic, Take a close look at what you are trying to do. iss... (by Handy Andy)
Creating header file "string" and all its functions
 
I got most of the code to work
[3 replies] Last: Try to call one function for time and see where the program craches. (by sourheart)
Error
 
anyone know why i am getting this error? error: expected primary-expression before '!=' token if (hasLazer != true or hasRadar != true or hasSeild...
[3 replies] Last: Are you sure that the error where in that line? Anyway i see that in ... (by sourheart)
If And Else Not Working Right
 
Hello i am still kinda new to c++, and i have been getting mad at this, for some reason my code will not work if and else. When i open the program and type som...
[3 replies] Last: Why: c++ is explict, and c++ logic states that zero is false, anything... (by jonnin)
Having Trouble With Setfill
 
Write your question here. #include<iostream> #include<iomanip> #include<string> using namespace std; int main() { double TotalTix, ANum, NNum; ...
[2 replies] Last: cout << setfill('.') << left << setw(35) << "Percentage of Gross Amo... (by CantSpel)
Monty Hall problem in c++
 
So my assignment is to solve the monty hall problem, which i am sure you guys know already. Here's my code so far, and I'll explain where did I got stuck #i...
[3 replies] Last: Thanks guys, I understand the logic, but professor require us to have ... (by barry23)
Code not working!
 
For this project, you will simulate this conversion. Your program will ask the user to enter a 4 digit numerical value. As the programmer, you will inp...
[3 replies] Last: Hello marygamess, After running the program for awhile I noticed this... (by Handy Andy)
by RanGH
BuBBle alghortim
 
Hello guyz. I have 1 trouble here about explanation of Bubble alghorithm. I have some code here and need verbal explanation step by step. Here is Function of bu...
[4 replies] Last: Here is a different version: void bubblesort( int arr , int n ) { fo... (by keskiverto)
Payroll Class App
 
HI, so i need to make a program that reads from file and displays info. but a class has to be used and header and and another cpp file for implementation, i ha...
[no replies]
Learning loops: decimal to binary
 
I can't figure out why my code isn't working. I am trying to convert the users input from base 10 to binary. I went through it a few times and I just cant figur...
[3 replies] Last: Thank you so much. I'll follow your advice and do the code the other... (by closed account 2hM9Nwbp)
cant get this coding to work properly
 
So first things first, I am taking a C++ course in college and the assignment is the whole Haverly's calculator problem that some of you here may know very well...
[3 replies] Last: Thanks for the tips, I thought about doing the switch first but then i... (by newbstarter)
moiter scren
 
Write your question here.i WROTE "MYFIRST PROGRAM" IN visual studio community 2017 version. I have to add #include "stdafx.h". second after I run debugger. Why ...
[1 reply] : Because the program finished. It opens a console, executes, and once... (by jonnin)
Payroll program using classes
 
Hi everyone! I'm very new to C++ (this is my first semester). I have to create a payroll program using classes that will read from a file (contains employee nam...
[1 reply] : You did not implement the constructor Payroll(); . One way to do that... (by coder777)
February 2018 Pages: 1... 1920212223... 28
  Archived months: [jan2018] [mar2018]

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