Beginners - September 2014 (Page 20)

by rezora
Problems with constructors and destructors
 
Hi I'm having trouble with this program I am trying to create, I was giving a set of code for int ma...
[no replies]
by Ch1156
Inheritance help
 
So I am doing some inheritance but whenever I try it I always never really see the point as I can ju...
[4 replies] Last: In your case your elf class is not needed. You would be better with ad... (by MiiNiPaa)
Help with functions and structures
 
Hello guys, i'm seeking help again here. I've been trying to practice structures and functions altog...
[2 replies] Last: Thanks, i can't believe i'm so stupid :P Again, thank you, problem so... (by Fedelway)
Can anyone help me with this?
 
The code Below works just fine.. it will print all combinations from number 1 to 25, in and array of...
[2 replies] Last: thanks! (by gabsacr)
Simulation - Running Total
 
I am writing a simulation program and everything works fine except the running total. The simulat...
[1 reply] : OK, I just realized my cout << totalCost; was in a very bad place.... (by jdwright)
Output C++
 
Output of the program : //INPUT VALUE OF A =0 int a,b=3; cin>>a; if(a) b=a++ -1; cout<<a...
[2 replies] Last: thanks a lot :) appreciate it ..it helps (by Naman29)
by LuckyR
Misunderstanding the code I've written and it's generated output
 
Hi guys, this will probably be a simple question and solution, but I'm not grasping it at the moment...
[3 replies] Last: yup 0==0 -> true 1==0 -> false 2==0 -> false (by garylee)
Anything above
 
Hello, I am currently working with a project and I am stuck. I'll give an example so you guys un...
[2 replies] Last: Thank you so much! :D (by BlankSpace)
by aLx450
output a _getche() value using toupper
 
Hello all, I'm building a very simple calculator program for currency exchange rates where the us...
[4 replies] Last: Yes, you can. I see you already using conio.h. In future: do not do th... (by MiiNiPaa)
by BC300
Exception Program with Classes
 
I'm having trouble with understanding how classes are used with exceptions. Since I'm working with c...
[6 replies] Last: C++ also comes with a few standard exceptions (runtime_error, logic_er... (by JayhawkZombie)
by Putler
size_t vs size_type and ptrdiff_t vs difference_type
 
Are there any differences between these types?
[1 reply] : size_type and difference_type are class member types which gives i... (by MiiNiPaa)
Compound interest function
 
Hello guys! I am writing a function that calculates a compound interest. It takes 3 parameters. ...
[16 replies] Last: Ah well, as long as it works. I suspect you need to make sure all data... (by closed account 48T7M4Gy)
(C++) 4^20 problem
 
Hey guys, I'm a total newbie and I suck at programming. I have following problem: For CompSci. c...
[6 replies] Last: Thank you very, much now I get it. I managed to get correct, uncut res... (by anndurill)
by mtmsl
Sequentially Outputting Elements Of An Array
 
I've been working on an example from a book, which says to do the following: Write a C++/CLI prog...
[2 replies] Last: Yes, there seems to be a flaw in your algorithm. I believe your code f... (by squished18)
by EvE12
Arrow member selection
 
Just wanted to ask if arrow member selection operator is used to access a pointer from any function ...
[2 replies] Last: thanks (by EvE12)
what happens internally in the below function call
 
Hi all, int func(int&a,int&b) { //some statements } int main() { int a=10,b=20; ...
[3 replies] Last: As I said, that depends on the optimizations the compiler may perform.... (by helios)
Displaying relevant values from an array
 
My task is to create a program that allows the user to input int values. It will then count the occu...
[1 reply] : Why are you checking ary but outputting values from intCount ?... (by MiiNiPaa)
Why isn't it giving the factorial properly.
 
Write your question here. #include <iostream> using namespace std; long fact(int n) { ...
[1 reply] : 1) while (n>0, f<n) is equivalent to while (f<n) 2) you are multi... (by MiiNiPaa)
why a macro defined as member function cant access the private data.
 
Hi All, why a macro defined as member function cant access the private data. class A { int x...
[2 replies] Last: Macros are expanded before compilation starts so they doesn't care abo... (by Peter87)
Operators, Variables, Objects
 
I'm just beginning to learn C++, and in the book I'm using as a guide, it asks me--as an exercise-- ...
[4 replies] Last: Well done. The point about putting it on the right line is the machin... (by closed account 48T7M4Gy)
September 2014 Pages: 1... 1819202122... 51
  Archived months: [aug2014] [oct2014]

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