Beginners - February 2015 (Page 36)

Calling another function from a file with it's own main.
 
This is for homework and my own understanding, so I'd appreciate being walked through the situation as oppose to being directly shown the answer so I'm going to...
[4 replies] Last: Alright, thank you, that is what i thought was the case, it's good to ... (by Bencojo)
Fixing code
 
When running the code, the output displays the same numbers for the net pay, average and total. What am I doing wrong? #include <iostream> #include <strin...
[8 replies] Last: The only thing wrong now are the formulas? And the fact that total ... (by dhayden)
by jjj
need help fixing program
 
hi i am new to c++ and i really need your help, could you please show me what I'm doing wrong. At the local supermarket, hotdogs are sold in packages contain...
[3 replies] Last: I see that you wanted nothing mentioned if there was no leftovers. Her... (by gkraft)
C++ Program
 
I am trying to create a program that displays the roman numeral equivalent of any decimal number between 1 and 20 that the user enters. The roman numerals shou...
[3 replies] Last: There are... Quite a few errors there... I don't even... You should us... (by tristan1333)
by bigbzt
ATM program with switches
 
Hey guys bit of newbie with coding, only my second code ever. Having a bit of trouble getting my program to compile. Im sure they are easy fixes but im just not...
[3 replies] Last: It probably wouldn't compile if you were missing a break or }. (by tristan1333)
reversing number
 
im writing a program to reverse number however i am having trouble with it. ex: input: 123 output:321 #include<iostream> using namespace std; ...
[5 replies] Last: Did anyone actually look at OPs code? @axel609 your rev_digit function... (by naraku9333)
by cibide
2 codes, same objective
 
Guys, why do this 2 codes give me different asnswers? #include <iostream> using namespace std; int main() { int SumUp = 0; int nX3CMax = 333; for (in...
[3 replies] Last: You are both right... ty... and sorry for variables names, I will do b... (by cibide)
by ReapZ
cin.get() and cin.ignore() to find next character.
 
i am working on a basic program to encrypt/decrypt a message based on numbers being equal to a letter. i am wondering how i can use cin.get() and cin.ignore() ...
[3 replies] Last: ne555 that would work but i need to enter the entire encoded message a... (by ReapZ)
For loop trouble, possible logic issue
 
I have to create a game where there's a four digit number that I predetermine in the code and the user has to try and guess the correct number. I have set the...
[5 replies] Last: http://www.cplusplus.com/doc/tutorial/control/ has explanation that mi... (by keskiverto)
abc
 
abc
[2 replies] Last: Double post: http://www.cplusplus.com/forum/general/156253/ (by cnoeval)
by cibide
Infinite Reaction
 
Hi... I was trying to create a programm that writes all numbers that are multiples of 3 and 5 but when I run it, the result is infinite... and I can't find the ...
[1 reply] : Pay attention to the difference of 3 << 1000 and 3 < 1000 One is ... (by keskiverto)
by nemimi
Even or odd followed by multiplication
 
I'm working on a homework assignment for a beginning C++ class and I'm a bit lost. Here's the assignment: Create a c++ program which ask the user to input a...
[6 replies] Last: Hm. I usually use c++ to compile. I'll try g++. Thanks! (by nemimi)
Help with Nested Structures
 
I was wondering how is the proper way to do the calculations using a nested structure. I was asked to write a program that contained a nested structure and calc...
[3 replies] Last: add the 9 employees to an array. create a function to do the calculati... (by shadowCODE)
Compiler Issues For Assignment
 
I need help with this assignment. It had some compiler issues on it, some of which I managed to fix, but there are others I don't understand. The code is long, ...
[6 replies] Last: Other issues: - Each of the professor's comments about the functions ... (by dhayden)
Prime number simple error
 
if i substitute with a=1 and then counts==2 its working, but not with this logic, whats wrong in it? #include<iostream.h> #include<conio.h> void ...
[1 reply] : Simple enough for you to figure out for your self that for every num... (by shadowCODE)
Need help with reading a file into a loop and processing
 
I'm new to this and feel totally lost. The problem is to read info from a text file into a program that will calculate total sales and average daily sales for t...
[1 reply] : You have an extra closing curly brace right after your while loop. Rem... (by Stremik)
using DevC++, working on input stream, having input file linking issue
 
I am writing code for input and output streams, i have 2 files in the same working directory of where my code file resides, but i am having issue that my stream...
[no replies]
by Durpo
While Looping and Odd Numbers
 
Hello everyone, i was hoping someone could clarify as to why my code isn't working. I'm fairly new to c++ and didn't know who else to ask. If i'm doing anythi...
[4 replies] Last: all i need is to make line 13 into z>0 for it to work You don't even... (by dhayden)
Need help with (while loop)
 
I'm starting to learn about while loop, and still kinda confused how to use it. Could you guys help me update with this code. // UPDATE THIS PROGRAM SO YOU ...
[5 replies] Last: Thanks alot, shamieh n everyone. Thanks to your explanation, I underst... (by Akion94)
Converting ints to letters and vice versa
 
I'm trying to make a program in which the user decides whether they want to decode numbers into letters or encode a phrase of words into numbers. I'm a beginner...
[no replies]
February 2015 Pages: 1... 3435363738... 52
  Archived months: [jan2015] [mar2015]

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