General C++ Programming - May 2014 (Page 28)

Random Numbers
 
How do you do this... Write an instruction to generate a random number in the range -501 to + 50 ...
[4 replies] Last: use this int random_number; random_number = 501 + rand() % (50); ... (by IGI30)
by IGI30
Mouse coordinate position in window
 
After searching on stackoverflow I got this POINT p; for (int i = 0;; ++i) { HWND hw...
[5 replies] Last: OK thanks I'll do second one. because 1st one will be slower. (by IGI30)
switch/menu compiling problems
 
Hello all, I'm trying to write a program that has a menu with a switch statement. I'm getting "c...
[2 replies] Last: Good eye. I did add that since posting this. Still getting the errors.... (by njrobby)
adjacency list graph representation
 
"My Programm is crashing and i dont know why can anyone help..?" #include<iostream> ...
[1 reply] : http://www.cplusplus.com/articles/z13hAqkS/ (by Yanson)
by Kingv
help on final project
 
I'm writing a fantasy store to purchase items from and need help passing the arrays, I know I need a...
[2 replies] Last: #include <iostream> #include <string> using namespace std; class I... (by Kingv)
Executing Loops
 
How many times will the body of the loop below execute? for ( int index = 0; index < 10; index++)...
[2 replies] Last: I don't get it. Doesn't it take less time for the OP to read chapter ... (by prestokeys)
gather 2 parameters and send, POST wininet [Help]
 
I have a problem I need to post two parameters via wininet so I can save in a mysql database. So I w...
[1 reply] : Concatenate like in your third example. However, note that you may ne... (by Stewbond)
More Loops
 
Assume you want to use a loop to process an array of characters starting from the beginning of the a...
[1 reply] : a variation: for ( int index = 0; array != '\0'; ++index ) { char ... (by Stewbond)
Reading from a file
 
Assume you want to read from a file and place the data from the file into an array. The array can ho...
[2 replies] Last: Why are we still doing OP's homework for him? (by Duthomhas)
STRANGE CASE QUICKSORT
 
Well I am following the program with this line of numbers to sort it with quicksort, I am writing ev...
[3 replies] Last: I SOLVED IT (by paoloben9)
Positive numbers and dividing
 
Assume you want to make sure that the user enters a positive number that is divisible by 10 with no ...
[2 replies] Last: Please, no one answer his questions, else he will get encouraged to ke... (by prestokeys)
Simulate Pairs card game
 
Write a C++ program to simulate Pairs card game. The game is played by two players. It will ask user...
[3 replies] Last: He may be clever but he's not helping you learn c++ by doing it for y... (by Codermik)
Returns
 
Assume you have a function that needs to return 3 data items. What would be the best approach to use...
[2 replies] Last: There are situations where D would be a valid choice. For example, a f... (by helios)
by ezt
how to make the output 0.0000000001
 
I want to convert energy from joules(J) to gigajoules(GJ) 1 joules = 0.000000001 GJ and i use this...
[2 replies] Last: ats15, Thank you! It works!:) (by ezt)
by al1432
Prime numbers
 
So I need to write a program which tells the user if the number they input is prime or not. I have ...
[5 replies] Last: You should use a prime sieve for finding the primes. (by giblit)
by CRooky
print stars function in 1D array..??
 
I'm having trouble with my for loop near the end of the program was able to print everything else ca...
[2 replies] Last: So I will seriously quickpay someone to finish this code for me...! LB... (by CRooky)
Singleton Patern
 
Hi guys, I was given assignment which I'll post below. I'm having problems doing it because every we...
[4 replies] Last: Sorry, but it won't let me delete my previous post. The line static ... (by prestokeys)
Big numbers in Arrays
 
i have to create three arrays. my first array is going to be a 20 digit number if not less. this als...
[17 replies] Last: I think it's better practice to not put stuff like that in main. Put i... (by JasperBraun)
Puzzling Linker error messages!
 
Hey guys, I am writing an address book program. It has multiple header files and their correspond...
[4 replies] Last: > it would not help my situation since I am using an IDE that was your... (by ne555)
Adding Reciprocals - Loop
 
How to do the problem below using loop? Using loop... Output the total of the reciprocals of ...
[3 replies] Last: That may only iterate 9 times. I would use an int for your loop iterat... (by giblit)
May 2014 Pages: 1... 262728293031
  Archived months: [apr2014] [jun2014]

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