Beginners - September 2011 (Page 4)

by Welch
setting cout to fixed
 
I've been trying to learn C++ by reading a book I bought off amazon.com (I have beginner experience in Java then decided to switch to C++ as my 1st language). T...
[1 reply] : They are flags; values set to either on or off, and the state of them ... (by Moschops)
Little question
 
Does this coding take all int values? if(random >= 6 || random <= 9) I mean, can number 3 be part of this if statement?
[3 replies] Last: A leap year is any year divisible by 4 unless it is divisible by 100,b... (by littlek0shka)
First game/program , having some trouble. Any help?
 
This is my first game/program, the drinking game. The problem I'm having is the 'drinks' function isn't displaying any text, it always just displays 1. Why/how ...
[4 replies] Last: Well I decided I would teach myself programming about a week ago. I wa... (by Zexanima)
Lost Data
 
Hello all- I am a fairly new C/C++ programmer and I am running into a very strange problem. I have a simple nested for loop that is filling a location in me...
[3 replies] Last: Well, I'm more of a C programmer than a C++ one anyhow :) What debugg... (by ascii)
simple proofread (2 sec i swear)
 
i am a very early beginner and am now learning about functions. as an excercise i created this. i think its pretty straight forward but my computer is telling m...
[16 replies] Last: awesome! its working swell now thanks everyone. ill keep that saved so... (by f1ddl3r)
by vlad61
lists and erasing
 
Hello I am trying to erase parts of my list. I create the itterator and i am able to erase the iterator = my_list.begin(); but when i move through the list an...
[10 replies] Last: Try writing that code without a loop, it may help you understand what ... (by closed account DSLq5Di1)
Why Is This Happening?
 
Hello, I'm making a funny text based game and early into it I have a problem, starting on line 123 I want the user to choose from 1-4, but whenever I test it, i...
[12 replies] Last: As far as program structure, if you look at the source code of a full-... (by ascii)
what is CCMD
 
I'm assuming this means Console Command but am not quite sure. If that is the case would the binddefaults in the following source be the command you enter in th...
[3 replies] Last: I doubt it's an OS API function. It's common for pre-processor marcos ... (by closed account zb0S216C)
help returning index
 
This function is supposed to return the index of the highest temperature. What I have now returns the actual highest temperature so how would I change this to o...
[6 replies] Last: I figured it out. Thanks for the help guys. (by DocCeaser)
by Tryed
Really simple code, help
 
So, I've never programmed anything before and I kinda started playing with it, and Im trying to make a very simple thing, it counts to 20 after I press 0 and it...
[8 replies] Last: [quote=Tryed] int main () { int n; int *np; np = &n; i... (by closed account zb0S216C)
selecting a month
 
Hey all, I think that I'm finally getting the hang of this C++ thing. So right now, I'm writing a program that takes user input and outputs the date in three d...
[12 replies] Last: To return the month name, use something like this. int m; string mon... (by whitenite1)
*****Help!!!!!*****
 
Im having a problem with my program. Im getting the error invalid conversion from 'int*' to 'int' on line 46. Im not sure whats wrong with it cause im trying t...
[2 replies] Last: OMG WOW! thank you lol (by mackw44)
Trouble finding 2nd maximum number while using counter- help please!
 
I am a beginner programmer taking my first C++ class. I've had great luck so far just following examples/book information/instructor information/the occasional...
[2 replies] Last: This is the text from sales1.txt - 1000 1000 1111 500 1500 1000 2000 ... (by sgiusti88)
Help me understand something(part 2, pointers)
 
This is sort of bugging me as well. I have code that looks like so : struct debts mr_E = { {"Ima Wolfe", 2400.0}, {"Ura Foxe", ...
[3 replies] Last: Oh sweet, another shortcut (: Thank you hanst &disch for your repli... (by georgewashere)
Help understanding something
 
This has bugged me since the last time i read this chapter, I never understood or felt comfortable reading the following. for (i = 0; i < n && str ; i++...
[6 replies] Last: New question = new topic. Makes it easier to find stuff. (by hanst99)
by noobee
I dont understand why please help
 
I am taking a C++ class and I don't seem to be getting any help from my instructor. I am trying to create a program that can take four grades, average them out ...
[13 replies] Last: it got pointed out to me today that the swich () wont take conditions ... (by olzi)
by jalfor
& vs && Speed
 
Just quickly...I guess it's more curiosity than necessity; What is quicker, using & or && in this scenario: if (bool1 & bool2 & bool3 & bool4) system("...
[7 replies] Last: It's entirely possible that the two will produce similar or the same c... (by Disch)
segmentation fault :(
 
I have to create a function that takes a string and detects if it is a valid ISBN number. In my test code, it works fine but in the official test code that my i...
[1 reply] : Nvmd! Apparently, all I had to do was add an "if" statement checking i... (by Moe45673)
Explanation of code
 
I have encountered a section of open source code while working on a project that i do not understand. If anyone could explain this to me I would greatly appreci...
[3 replies] Last: Thank you Gaminic that link helped a lot. I feel like a retard for not... (by squirtman59)
by dznguy
order in which operator+ return
 
is there a way such that i could set the order is which operator+ can return? for example, if (a>=b) return operator+(a,b) else return operator+(b,a) ra...
[4 replies] Last: Oh! Sorry, misread the problem's code! (by Nisheeth)
September 2011 Pages: 123456... 48
  Archived months: [aug2011] [oct2011]

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