General C++ Programming - April 2013 (Page 37)

Need help writing a program
 
So the purpose of this program is to use functions, nested decisions, and sentinel loops to calculate the surface area, volume, or "Girth + Depth" of a box. I s...
[12 replies] Last: So far I have this. The functions are all working. Now I need to creat... (by ATzekovsky)
General question about multiple games running from one source?
 
So I am going to try and keep this as general as possible so as not to infringe on any plagerism rules. I have an assignment to make 3 board games run from o...
[5 replies] Last: You can define classes in C++ the same way as in Java. I have no idea ... (by LB)
Urgent: Help with a my assigment
 
Hello, I need a help with my lab assignment, I should submit it today, please if anyone can help me in this. ====== Write a C++ program that prompts th...
[13 replies] Last: Be careful of integer division when you say sum / count towards the ... (by booradley60)
by fefer
Need equation for assignment
 
I need an equation that determines the lowest possible cost for laying power line. The variables are as follows: 1. The width of a river 2. The distanc...
[4 replies] Last: I would imagine that the shortest length across the river is a path th... (by pogrady)
C-Programming Structures
 
Hi Guys, here is a question for you: It is possible to define a structure like struct test { int a; int b; }; and create an instance of it: st...
[3 replies] Last: Tested this on GCC 4.8.0. Works fine with a warning: designated_init... (by Catfish3)
Why are my if and else both executing?
 
I have a function with an if and else statement inside a for loop but both the if and else are both executing. What am I doing working? Thank You. int...
[10 replies] Last: It was simple. I set the function to a Boolean. (by JazzyJeff123)
Unreliable sizes for fundamental types?
 
I've been refreshing my knowledge of C++, and there's something that concerns me: The size of fundamental types is not guaranteed. Apparently, all the standa...
[6 replies] Last: MSDN documents Microsoft dialect of C++, it's quite possible that it's... (by Cubbi)
Code auto retyper
 
Hii, I was just wondering if there is a program that can retype the code in a neat way and in a different way, or even make it easier to change the name of the ...
[1 reply] : CHeck this out: http://astyle.sourceforge.net/ In Visual Studio, you... (by Stewbond)
which data structure for speed?
 
I have to iterate through a txt file with 370,000+ words, which data structure would you guys recommend? I started using a map<string,string> but it takes about...
[4 replies] Last: [quote=bob39rocks]ok i have to read a text file(dictionary) for a text... (by S G H)
by LB
Force stream << >> to interpret as binary
 
I'm writing custom stream classes for a project of mine, and I want to change the formatted extraction operators to interpret everything as binary rather than h...
[17 replies] Last: I'm not up for abusing anything. I just find it hard to believe that t... (by LB)
Can someone help me with this program
 
The user is prompted to enter 2 integers a and b such that a < b. Using these as starting and final values you are to set up a for loop that does the fo...
[5 replies] Last: #include<iostream> using namespace std; int main() { int a,b,f... (by NYC1988)
Need some help Heritance
 
main.cpp #include <iostream> #include "Personnage.h" #include "Pretre.h" #include "PretreDemo.h" using namespace std; int main() { string sName; cout <<...
[1 reply] : you are trying to access p1 in area where it is not visible (and actua... (by MiiNiPaa)
Explain functions
 
Can anyone explain functions to me? I need to write a 3 function program that calculates distance and slope, I am also using a bool function so that I can tell ...
[14 replies] Last: :P (by Major Tom)
can a friend function work for two classes?
 
Since a friend function is not a member of a class, can it be used for two classes for performing the same job? I guess no because we've to pass an object of th...
[7 replies] Last: Thanks everyone! (by Rehan FASTian)
HELP ME PLEASE WITH CLASSES
 
CAN SOMEONE PLEASE GIVE ME AN IN DEPTH ANSWER ON HOW THESE TWO CODES INTERACT WITH EACH. AN EXPLANATION ON WHAT IS GOING ON IN THIS PROGRAM. HOW EVERYTHING IS W...
[1 reply] : Use code tags: http://www.cplusplus.com/articles/jEywvCM9/ (by eklavya sharma 2)
creating a recursive function that will print out a number to a power
 
im trying to create a recursive function that i can call on in order to take a user inputed base and exponent and give final answer this is what i have but im c...
[3 replies] Last: Code Tags: http://www.cplusplus.com/articles/jEywvCM9/ (by eklavya sharma 2)
Polymorphism
 
I studied C++ syntax and OOP and could not learn about Polymorphism. Can anyone explain me in which area that i will need polymorphism
[7 replies] Last: MikeyBoy you are the boy! Thanks mate.You gave the perfect answer i wa... (by simplelenz)
What's wrong with my program?? Help appreciated
 
Re-posting for beginner forum, I haven't got any working suggestions there. They said I should implement a copy constructor but that didn't seem to help. What ...
[2 replies] Last: Of course, but I have tried to find what is wrong for a day now and I ... (by Tiger58)
Help with function
 
Task: Write a function: - exp(x,y): - where x is positive (possibly a decimal) and y is a positive integer. - Returns x to the y. - The definition of...
[11 replies] Last: Thank you! I traced the code and it works! Thank you for all your h... (by incognitocpp)
by flony1
class racional
 
Hello friends, I have this problem and if anyone got sick enough I can help out would be great, I program in visual c + + 2012 "Programming in C + + Deitel" P...
[3 replies] Last: I found the solution // Racional.h #ifndef RACIONAL_H #define RACIONA... (by flony1)
April 2013 Pages: 1... 3536373839... 53
  Archived months: [mar2013] [may2013]

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