General C++ Programming (Page 6)

Help on a for loop for triplicating bacteria!
I have to create a program that simulates cell reproduction of a bacteria. The user is to input a nu...
[1 reply] : cout << "Days" << setw(10) << "Cells" << endl; //Table headings fo... (by arbwok)
by Pete8
question about how to declare something
I'm encountering a problem involving ?something? named __asm__. It's not an int, and it's not a typ...
[4 replies] Last: if this isn't working, we used to have to call the "emit" assembler fu... (by jonnin)
(pcnf) discrete mathematics's project in c++
Hi everyone anyone can help me about how to write this project .the project is about tow statements ...
[1 reply] : you want to compare 2 symbolic equations, is this correct? (by jonnin)
by Kalcor
Expressing this functions in terms of big-o-notation
Express the function n 3 /1000 - 100n 2 - 100n+3 in terms of Θ-notation. Trying to understand how...
[1 reply] : big-o is a bit weird to come up with the FORMAL answer. Here, if N is... (by jonnin)
while(file.good()&&!file.eof()) run once more
Hi, When I run the following code, the while loop will run more once time. The file contents are: ...
[5 replies] Last: As cubbi explained, you read 3 records. No problem. The file is co... (by AbstractionAnon)
invalid operands of types 'float' and 'float' to binary 'operator%'
I am trying to fidn the largest prime factor of a very large number so i used float but i am gettin...
[1 reply] : fmod function. Use that for floating types. your number will fit in... (by jonnin)
by RezaAb
How to create a progress bar in C++
Hello guys, I have finished a code including a for loop with thousands of times calculations and ...
[4 replies] Last: That was basically a cut/paste from some code I have. Here is a worki... (by dhayden)
the console doesn't show full result
When i tried to run it, ran successfully but i couldn't see the full result result on the console sc...
[4 replies] Last: A workaround, not an ideal situation, is to rewrite your program to ou... (by FurryGuy)
by Kalcor
Concluding this condition
Now it's time of Olympiads. Vanya and Egor decided to make his own team to take part in a programmi...
[2 replies] Last: Love you @lastchance xP (by Kalcor)
by cmisip
Trying to understand std::find and std::equal_range
I am trying to see which Points are close ( within 5 pixels in both the x and y dimensions) to a sp...
[3 replies] Last: > it seems std::partition is the answer using a lambda function. > st... (by JLBorges)
by Kalcor
Can't seem to solve this
You've got array a , a , ..., a , consisting of n integers. Count the number of ways to split...
[16 replies] Last: Ah.. I get it now.. thanks alot! (by Kalcor)
by cmisip
Pointer assignment question
I am missing something here. Why can't I assign the address of a pointer to another pointer. Assi...
[10 replies] Last: I did not even think about writing a template and that's a great idea.... (by cmisip)
Calculating overtime pay using a void function
I was given a program that used double functions to calculate overtime pay. Hours 1 to 37 gets paid ...
[3 replies] Last: EDITED POST: @jj245037 figured it out, already. :-) Since you must use... (by chicofeo)
Creating a temperature converter using two void functions
/*Hi, everyone. I am having trouble making a converter that allows the user to input a number that t...
[5 replies] Last: Thanks a lot for replying so quickly, wildblue. I just discovered this... (by jj245037)
syntax help!
Hello Guys!, I need help undestanding the next line from the code below. Rectangle( int a = 0, int ...
[3 replies] Last: Rectangle is derived from Shape. So any time you construct a Rectangle... (by dhayden)
by TheArk
program exits
Hello, any idea why the program closes before allowing me to input? Doesn't let me input a thing, no...
[2 replies] Last: cout << if (weight weight <= 5) weight *= a; I don’t t... (by Enoizat)
What is wrong with my calculation? (Math vector problem)
I'm following along with a book I'm reading, though I've decided to implement my own Vector2D struct...
[2 replies] Last: > on lines 8 and 9 you calculate the same thing twice - maybe just cal... (by ne555)
Array indexing or index array-ing
In the code snippet below, line 7 is standard ... but why on earth does line 8 work? #include <i...
[2 replies] Last: That's great, @Peter87! (And thanks for re-editing.) With your pointe... (by lastchance)
'var' in class does not name a type
Hello, I'm trying to find out why this fails. I have searched internet without getting any useful in...
[4 replies] Last: At last, I found the solution. The correct code in the cpp file was: ... (by coredumped)
Pages: 1... 45678... 23
  Archived months: [apr2017]

Cannot post in this page. To post a new message, go to the first page.