Beginners - December 2010 (Page 30)

by ChemE
How to get a random number?
 
Hey, I've made a genetic algorithm program that's not generating very random numbers. Every time I run it, it generates the same ten million or so random numbe...
[3 replies] Last: Problem is in line 11.. You should have a function for random numbe... (by genesys)
using the delete operator error
 
Basically, I don't not how I can delete the new objects I've created in this array. Apparently, the I'm getting is the debug assertion failed #include<iostr...
[2 replies] Last: The thing is that new variables at declared at runtime and they need t... (by Blessman11)
just pop out an dissapear
 
Hello im learning c++ and i have a weird problem. Every time i click debug my program opens and then closes in a second. It basically just pop out. It happens w...
[1 reply] : http://www.cplusplus.com/forum/articles/7312/ (by Bazzy)
by Faff
Why not using namespace std?
 
Hello :) Was wondering why some people prefere not to use namespace std; and type std::cout<< x ; instead of just cout<< x; . So my question would be,...
[5 replies] Last: So my question would be, what are the downsides of using namespace s... (by closed account z05DSL3A)
by pmikee
Redirecting the console output into an array?
 
Hi! I have a problem with 2-d arrays, what i cant solve...I have to write a program, that settles if the most frequent birds peculiar to an area were the same....
[no replies]
writing header file
 
i'm now writing a header file how to read item data form specified file and store them in an array. and the value of a varible N should be updated accordingly....
[1 reply] : http://cplusplus.com/forum/articles/10627/ I think this helps you (by firix)
by firix
c++ ebook ?
 
Hi I want to ask you something I have read the book two times in C + + programming language(Bjarne stroustrup). now I want to read the following books which...
[2 replies] Last: thanks visualbasi (by firix)
Why don't work?
 
Hi everyone, I'm try to learn C language, but am having trouble. Look at this code, why it does not work? It was to enroll 5 books and then print the five...
[3 replies] Last: int seq; char *livro ; void cadastra(char * nome, int ordem) { ... (by firix)
Days Instead of Years
 
Hi, I am writing a program that tells the user their age on days, however, at the moment, it outputs it in years, how can i make this output in days (im thin...
[5 replies] Last: u can use three for loop to calculate the days between two date one b... (by visualbasi)
Handling Exception
 
#include <iostream> #include <string> #include <exception> using namespace std; int getInt(string prompt) { int integer; cout << prompt; if(!(ci...
[2 replies] Last: you look here http://www.cplusplus.com/reference/std/stdexcept/ (by firix)
Clear?
 
Is there a command like "cls" in .bat (clears the window of any text) for c++?
[2 replies] Last: http://www.cplusplus.com/forum/articles/10515/ (by Null)
1st Program Failed - fatal error LNK1120
 
So I'm a wannabe C++ programmer who just got started with Microsoft Visual C++ 2010 Express. I wrote my "Hello World!" program, but it failed. This is exactly w...
[1 reply] : try using // my first program in C++ #include"stdahx.h" #include... (by tuandt5)
Building using media libraries
 
This is probably a very silly question but Google has failed in answering me. Let's say I build some kind of program using X media library (SDL/SFML/Allegro/...
[5 replies] Last: http://publib.boulder.ibm.com/infocenter/aix/v6r1/index.jsp?topic=/com... (by hamsterman)
by talt1
A string that returns what I type in?
 
Ok, so I am trying to write a string that returns what I type in and it works until I start putting spaces between my characters. How would I go about fixing ...
[2 replies] Last: it worked thanks (by talt1)
by ChemE
Linker bug in code that was working
 
Genetic algorithm program worked a few times, but the very same code stopped compiling a minute later. Only one constant value was changed in the code (from 50...
[1 reply] : Update: I took out int iRandCust(int lowerBound, int upperBound){ ... (by ChemE)
getline() and text file problems.
 
Hello! I'm glad to have finally made an account here, hopefully someone can give me some direction on this little issue i'm having. I'm using the getline() f...
[1 reply] : Well, somehow putting myself out there by asking a question resulted i... (by ronalthompson)
goto or similar
 
I was wondering if there was a command in c++ like the "goto" command in .bat files, and if so, how do i use it?
[2 replies] Last: Yes I did see that, along with many people saying it was a very bad id... (by jjw1993)
looping music in the background of your program
 
Alright, so I figured how to do just basic playing sound using the PlaySound() function that is part of windows.h... When you run this specific function in the ...
[4 replies] Last: Alright, thanks guys. Will look into the SFML, i'm a game programming ... (by ERanz21)
for loop/array issue
 
I am making a script for a final project for class that is supposed to calculate the bill for a lawn mowing service. Everything works good except for one for lo...
[2 replies] Last: Worked great! Thanks for your help! (by Patch3s)
Integer memory overflow?
 
Hey all, I was wondering if it was possible to overflow memory after an integer input from the following code: int n; cout << "Enter the size of the arra...
[3 replies] Last: When an integer overflows, the most significant bits that don't fit ar... (by Athar)
December 2010 Pages: 1... 2829303132... 35
  Archived months: [nov2010] [jan2011]

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