General C++ Programming - September 2012 (Page 29)

.h and .cpp file what should be inside either one.
 
As the title says, anyone can tell me what should be in a .h file and a.cpp file and maybe you can illustrate with an example with some simple lines of code. mu...
[1 reply] : http://www.cplusplus.com/articles/Gw6AC542/ (by Moschops)
intro to object oriented programming qn
 
Objective The objective of this problem is to introduce a simple Object-Oriented Programming (OOP) problem and ensure that students understand the concept of O...
[1 reply] : I would probably create a Person class, with a string name, integers f... (by MrHutch)
SDL - DEV C++ problem
 
Hello! Iam programming with DEV C++ and I setup everything with this tutorials. https://sites.google.com/site/sdlgamer/beginner/lesson-2 http://lazyfoo.net...
[1 reply] : -lSDLmain <- Should be a lower case L. (by Peter87)
help me with this error (expected unqualified- id before '{' token ) the bold codings
 
#include <iostream> #include <fstream> #include <cstdlib> #include <iomanip> using namespace std; class product { int pID; char na...
[1 reply] : Hi there, You need to remove the ';' at the end of the declarator: ... (by closed account o3hC5Di1)
Problem with templates
 
I am getting this error and warning: error: invalid declarator before '(' character warning: deprecated conversion from string constant to char* wi...
[10 replies] Last: Yes. The the lexer/parser will expect a specialisation after template... (by closed account zb0S216C)
The bare essentials for C++ Game Programming
 
Pretty simple question, what are some of the skills/techniques you need to have a good understanding of before you start C++ Game Programming. E.g. Loops, Array...
[3 replies] Last: Really depends on your interpretation of "C++ Game Programming". Ther... (by MrHutch)
Need A Program urgently..
 
program to find the area under the curve y=f(x) between x=a and x=b,integrate y=f(x) between the limits of a and b..
[1 reply] : http://en.wikipedia.org/wiki/Numerical_integration (by R0mai)
PROBLEM WITH AN ARRAY BASED STACK.
 
Hi everyone, I've been trying to write a stack updating member function for a class called stackType. The stack is array based and the function takes a paramete...
[2 replies] Last: its a school assignment on a data structures course. (by ayanda83)
Need guidance on this c++ program. Kind of confused
 
So I am writing a program. I ahven't programed in a year do to a medical issue but I am back in it. WE have to write a word counter program that reads the wor...
[6 replies] Last: Hey why not try in scripting, like batch script or shell scripts ? Tha... (by acn)
help me to make the header file for the movie ticket system..
 
#include<iostream> using namespace std; int main() { // added total2 to calculate overall sales int seat, adult, child, total, total2; char flag; sea...
[1 reply] : Hey thedoung, You just posted out is a program that show ticket booki... (by acn)
Recursive or iterative algorithms?
 
In general, which is more useful and efficent in algorithms? I feel a recusive algorithm would be much more memory intesive because of its constant re-calling o...
[4 replies] Last: I agree with ssrun, and off course with helios and athar, that wheneve... (by acn)
Dictionary search
 
i am making dictionary and in that i wanted to search word..because there are millions word in that so i would like to implement best one..so please tell me, w...
[6 replies] Last: @AbstractionAnon: i want to use my own data structure. STL will increa... (by HiteshVaghani1)
Help with char and if statements! (1,2)
 
I have to write a program that ask the user to type in a character which will be stored(this character has no use). After that the user is asked to type in the...
[24 replies] Last: Ok, Thank you so much! (by sbgreen6592)
Class problems!
 
I'm new here, nice to meet you guy! Here's my exercise: #include <iostream> #include <cmath> using namespace std; class ThreeD { double x; double ...
[2 replies] Last: thanks so much! I understand now! (by hitman17528)
String appending problems C++
 
Hello, I'm using a program in wich in order to put characters on a output file, first I insert them in a string, so I can later put them in the file. for ex...
[5 replies] Last: Well first what did you change. (by closed account o1vk4iN6)
check whether character is digit or alphabet.
 
i have been given an assignment to check whether a given character is a digit or an alphabet but without using the header file <ctype>. I tried but can't fin...
[4 replies] Last: You could also use the functions from <cctype> without including the... (by closed account DSLq5Di1)
by Numeri
Reading a Text File into a 2d Array
 
I am trying to read this text file: & @d| dddd| ----| into the char array Map . My code just doesn't work. char Map ; int row=0, col=0; void Refresh...
[4 replies] Last: Thank you so much! (by Numeri)
vector looping problem
 
I'm writing a program to demonstrate static memory partitioning. The program takes user input for 5 partition sizes and then user input for any number of job si...
[1 reply] : Well, I figured it out. I added a couple if statements to the beginni... (by ecallen)
Qt Move textcursor to right click point
 
Hi all, I'm making a simple text editor with qt. At the moment I have a standard context menu which appears upon right-clicking . I need it so that as soon as ...
[1 reply] : And the answer is QTextEdit:: cursorForPosition. (by rozick1)
segmentation fault
 
Hi, I have a problem with a program I've been writing for the past couple of days. The series of events that lead to noticing the error are: - start the progra...
[2 replies] Last: It's okay I fixed it. (by hector409)
September 2012 Pages: 1... 272829303132
  Archived months: [aug2012] [oct2012]

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