Beginners - October 2012 (Page 59)

Help with my excerise
 
So im in the middle of trying to teach myself c++ by reading C++ Primer the fourth edition, and im stuck on one of the exercises and could use some pointers to ...
[4 replies] Last: It's exactly like you said. You're using the first version of the func... (by maeriden)
Help for for loop!
 
void Test::Test2() { int menuChoice; cout<<"Welcome!"<<endl; cout<<" "<<endl; cout<<"1) Choice1"<<endl; cout<<"2) Choice2"<<endl; cout<<"3) Ch...
[9 replies] Last: A question before everything else: does your code get compiled? Becaus... (by maeriden)
count digits in user input
 
My English is very bad but I hope you can understand me! Furthermore: I have never programmed before and this year I started with a study where programming is ...
[4 replies] Last: Yes I got it! Thank you! (by dutchman)
by ezis15
Need help with an exercise.
 
So i got an exam now, and i am not ready for it, so im counting on you guys! N people came to conference. Transporting them from hotel to conference a number...
[1 reply] : your if statement is incorrect, you need to break up the statement eve... (by Need4Sleep)
Ascending and Descending order
 
just wanna ask... what function will I use so that the program will ascend or descend. I tried If but I need lesser code... here is the part of the code. ...
[3 replies] Last: We could work on your code. To sort number, you could use std::sort(... (by ne555)
declarations and definitions
 
Hello guys. I'm very new with C++ and I'm trying to understand the difference between a declaration and a definition. As far as I understand, a declaratio...
[2 replies] Last: You're close, you're only off when you say "not a value" -- a definit... (by theuser)
sprite sheet help
 
Hi guys, Started working with SDL, and right now I am going through a few tutorials. However, they supply the sprite sheets, and the dimensions they are extr...
[2 replies] Last: Thanks naraku, I like both ideas; simply take the dimensions and do a... (by toomanystars)
by clodi
questions on "classes"
 
Hello guys, I've been reading through a few chapters on 'classes' The prolem is that what I understood is very little, plus, I am reading many threads in he...
[9 replies] Last: Hey i know the questions answered but in your first post you asked if ... (by TheBeardedQuack)
strcpy() changes return array
 
Hi all, I don't understand line 29: template <typename T, int nSize> // nSize is the expression parameter class Buffer { private: // The expression p...
[3 replies] Last: I see. And now I understand SDL_PollEvent( &event ) as well. Thanks!... (by Fransje)
array declaration and definition
 
Hello! I have the following problem. I declare in someClass.hpp file some class with static members: class A { ... public: static int arr ; ... ...
[3 replies] Last: You could change the array into a pointer and allocate it dynamically.... (by helios)
by TomUIC
Extracting data from a file
 
Hi there, Well my assignment is to pull data from a census file, namely enter a name and extract the history of it's popularity. The txt file has each name a...
[1 reply] : Simple solution is to introduce a flag bool nameFound = false; while... (by codewalker)
Operation on using Class
 
Hello, we were tasked to create a polynomial class that will do the basic operation. I have a working constructor already. I don't know how to make the oper...
[4 replies] Last: I changed it to this plus I also added the const in the operator and i... (by Amethyst)
what is the code for a reservation of an airplane ticket???
 
please help me.this is our finals project..
[3 replies] Last: @Zhuge Like a boss :) (by vichu8888)
Reading from a file help finishing code
 
program reads from a file (sales.txt) containing records in the format string int double. the string is a productID, the int is a quantity, and the double is a ...
[1 reply] : #include <iostream> #include <string> #include <fstream> #include<iom... (by vichu8888)
Track Local Max and Min Values for X and Y
 
will this code work? void Box::setMoreData() //track local max and min values for X and Y { for (int j=0;j<4;j++) // 4 x Coords { if (xcoords > xco...
[5 replies] Last: sorry nvm. (by ilovelearning)
friend operator function
 
Hi all, class Cents { private: int m_nCents; public: Cents( int nCents ) : m_nCents( nCents ) {} friend b...
[5 replies] Last: I this case the operator > has access to the private and protected mem... (by pogrady)
I am very new to this.
 
I was able to get everything to work howeverthe last part should print like below. Can anyone please give me some idea of what I am missing? Thanks.. Output ...
[2 replies] Last: I think u didnt call the void Addsomethingup (EmployeeClass Emp1, Emp... (by vichu8888)
Need help passing 2d-array between classes
 
So i've created: main.cpp (creates 2d-array, then makes calls on 2 functions and passes 2d-array) functions.cpp (contains 2 functions being called) functions...
[1 reply] : functions.h: namespace func{ int findWord(char (*Array2D) , int i, ... (by pogrady)
open hash using chained lists
 
Hi! As a homework from college i have to create an open hash to store certain struct called "server". I defined the hash as the following: struct List...
[5 replies] Last: Sure, you can use a double pointer/array of pointers (if your hash tab... (by BlackSheep)
Need some help with my RPG...
 
So, I'm a newbie at c. Started watching videos constantly and reading books a week ago and decided to try out making an RPG game for command prompt. I didn't kn...
[6 replies] Last: I don't know if anyone will still be willing to help me with this, but... (by mrjynxftw)
October 2012 Pages: 1... 5758596061... 84
  Archived months: [sep2012] [nov2012]

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