Beginners - January 2015 (Page 3)

by Chase
using sort() on protected variables
Hi! I was using #include <list> and sort it with sort(). The problem is that i cant sort the member variables outside the class because they were set to protec...
Jan 30, 2015 at 2:59pm
[3 replies] Last: Not sure what you're trying to point out with the two copies of your c... (by AbstractionAnon)
Player vs Skeleton v1.0 HELP!!
I've made a little program that simulates a battle between player and skeleton, however 2 problems I'm facing is level up when it's not suppose to level up and ...
Jan 30, 2015 at 2:35pm
[10 replies] Last: Wow so stupid of me ahaha that's why it was levelling up....alright ev... (by nerdpwn)
can someone help me this the project can i get help on this one i am new to this
this what i am suppose to be doing fi!c):Iir0t,"ram mUS* *18VC a ^unc1,on for cnch Here are the funUion\ (name nuj not mutch name in Opot the 1,1c Write thi*...
Jan 30, 2015 at 1:43pm
[5 replies] Last: Process Card Suits: You are to write this function and document it com... (by lordx109999)
data member init.
int enterSide() { int enter; std::cin >> enter; return enter; } // this is defined in the class void area::getSide( int x , int y , int z ) { side1 = x; s...
Jan 30, 2015 at 12:23pm
[5 replies] Last: Hello again, Just some other ideas: If you need to work out the area... (by TheIdeasMan)
c++ declaration
i want to write a programm,which takes an input from keayboard and if it 's char it is stored into an array ,if it 's int it is stored into another array.The pr...
Jan 30, 2015 at 11:52am
[1 reply] : Declare your x as char array. After getting input, try to parse it w... (by MiiNiPaa)
by NikD
Storing data in a map of vector<double>'s
Hello everyone, I am trying to read a file with a lot of data and store this data in a map with vectors. The file has one line of strings as the first line, wh...
Jan 30, 2015 at 11:05am
[14 replies] Last: your sample data columns don't match you have 11 string column header... (by rafae11)
Hi!
How do i repeat my program? if i press Y or N in loops infinitely #include <iostream> using namespace std; int main(){ int choice, num; char a...
Jan 30, 2015 at 9:12am
[1 reply] : You are checking against again but you don't use again in your program... (by rafae11)
Question on mean and standard deviation
I got the correct results of deviation but something wrong with the value sum. Really confused about it. #include <cmath> #include <cstdlib> #include <ios...
Jan 30, 2015 at 8:57am
[6 replies] Last: Thank you so much!!! Then why was i reported...? (by mutexe)
by shola
Nested Loop Problem. Help me to figure out.
[Step 2] Modify your program from step 1 to now query the user for a value of Θ between 15 and 75 (you can assume they will always comply and not give you a b...
Jan 30, 2015 at 8:50am
[1 reply] : i suggest adding this: cout << "Length: " <<length<< endl; after ... (by mutexe)
how to make it work
Jdjrnbrnrkskksjsbbekwkwk
Jan 30, 2015 at 8:42am
[1 reply] : Be more specific: What are you trying to accomplish? Where is the prob... (by coder777)
Need clarification on using namespace
Hi, A bit new to C++ and was wondering if someone can clarify something for me? So I know that "using namespace xxx" tells the compiler to look in namespa...
Jan 30, 2015 at 7:06am
[1 reply] : See: Koenig look up: http://en.cppreference.com/w/cpp/language/adl Ko... (by JLBorges)
by shola
Need help. Prime Time
Can anyone help me figure out what I'm doing wrong in my code. It seems that it only divides entered number by 2. My idea is to divide the entered integer by 2...
Jan 30, 2015 at 4:39am
[3 replies] Last: Thank you very much! (by shola)
Error in `./a.out'
We asked to add a reference to a student record, called bestFriend. The function displayStudentRecord(student *s) should display the first name, last name, and ...
Jan 30, 2015 at 1:31am
[2 replies] Last: That's cool. I just realized that. Requirement: • assign the second... (by juliuschen)
Why wont this work???
What am I doing wrong? #include <iostream> using namespace std; template <class T> class Math{ public: T add(T *x, T *y); T GetInfo(); ...
Jan 30, 2015 at 12:36am
[1 reply] : What are you doing wrong? cout << MathObject.add(*number1, *number2)... (by megatron 0)
How to make my program read previous lines of code?
Long version: Hello to anyone who reads this. First off just let me say that this is my first time making a topic on these forums so sorry if I do something wro...
Jan 30, 2015 at 12:30am
[5 replies] Last: Thank you for explaining this. I now understand most of it and i'm get... (by Michael50124)
by Sh0es
Istream Ctor
I'm having compiler errors associated with this block of text. I've added comments pertaining to the errors. class PwdReader //interface for reading the p...
Jan 29, 2015 at 10:02pm
[6 replies] Last: The move constructor for std::istream is protected. std::ifstream ... (by JLBorges)
by kiri
Else if...
I love posting here because you guys teach me something everyday. Please help me! In the code below there is a else if and when you enter 9 it is suppose to say...
Jan 29, 2015 at 9:58pm
[16 replies] Last: You're welcome. Here's an important tip for you, one that I've learned... (by aLx450)
malloc problem
I would like some help for the following code. The output should be: hovercraft but i get: Xovercraft instead. I do not know if i messed up my code::blocks ...
Jan 29, 2015 at 9:50pm
[3 replies] Last: I suppose you mean that i should use better names for variables, mor... (by mutexe)
by aLx450
Extracting values from large array to put in smaller array
Good day everyone, I've been throwing this around in my head for a while, but it just does not make sense so here goes. It's for a school project so the synt...
Jan 29, 2015 at 8:38pm
[3 replies] Last: Just to be sure, aside from pointers, or vectorizing the array, there... (by MiiNiPaa)
Switch Statement Menu STILL NEED HELP! PLEASE AND THANK YOU
Figured it out after a bit. Thanks for your input though guys. Always a nice help ^.^
Jan 29, 2015 at 8:20pm
[3 replies] Last: Your use of switch is corect. Program is probably not running properly... (by TheHardew)
January 2015 Pages: 12345... 39
  Archived months: [dec2014] [feb2015]

This is an archived page. To post a new message, go to the current page.
Registered users can post in this forum.