General C++ Programming (Page 31)

Problem about getting the number greater than the average
 
#include<iostream> using namespace std; int main() { int k,num,sum=0,GreaterNO=0; double average;...
[8 replies] Last: Get the point dy, thx alot (by ryushin)
Testing auto feature on C++11
 
Hi friends, Am trying to test this new 'auto' feature on C++11 version. Here is my problem: ...
[5 replies] Last: haha ic, thanks Peter :) (by sansoftaus)
Multi Tasking
 
Windows can keep track of multiple programs at once. How can you emulate something like this in C++?...
[4 replies] Last: Bah, you win. It sounds like it's pretty complicated to do though and ... (by RealGiganitris)
by gudeh
Sites communication, Sockets and Win32 API
 
Hi there, I saw a post here from 2008 where a guy asked: "how to get data from internet?".(http://ww...
[1 reply] : Should I use sockets or this thing about API? Use sockets. But you d... (by kbw)
Int, long int, and string
 
I have a simple question that im not sure of. When do we know when to use int, long int, and string....
[2 replies] Last: http://www.cplusplus.com/forum/beginner/110492/#msg603267 (by JLBorges)
by Niven
A* Search keeps crashing
 
I'm attempting to implement A* search in one of my programs, but everytime I run it, it crashes. Rel...
[3 replies] Last: > the queue would end up holding enough data that the stack ran out of... (by ne555)
Access Reading Violation
 
Im working on a BST homework, and I have been doing alright, but I keep running into this error that...
[3 replies] Last: My code is quite large. It's actually why I shrunk it down. But I will... (by Bonster)
for loop help
 
I have this for loop that does this: let say n = 8 and node = 4 n: id: 0 1 2 3 0 ...
[1 reply] : I don't know how to explain it =..=. So is this what you want? #in... (by lsk)
Calculate variance in C++?
 
I am using the valarray function to take the numbers in myarray, and subtract them from the mean to ...
[1 reply] : Why can't you just myarray -= mean; ? Then print it, and then use it ... (by Duoas)
How to read files inside a folder using the value from another input file
 
Hi. I am currently doing my assignment and it requires me to open a folder, read a file, and then op...
[no replies]
Puzzled about virtual function using in pthread
 
Hello. I write a job class base to do some background work using pthread, but I encounter some stran...
[no replies]
Rehashing the Matrix
 
Hey guys, I'm new here so forgive me if I'm doing this wrong. I have this assignment where I hav...
[1 reply] : Here is the source code for the class #ifndef SPARSEMATRIX_H #define... (by theguy920)
by tcmn
returning the number of elements in a list
 
I am given an array with n elements but need to write a function where it returns n-1 elements. Do I...
[5 replies] Last: The basic principle is: index of current node = 0; while (index of ... (by Duoas)
Need help with age finding program.
 
The problem is that I need to figure out the user's birthday in months, days, hours, and minutes fro...
[3 replies] Last: Oh, okay. Wow. That's way different than what I had. I'll try workin... (by nibiruis)
confusion about reference and pointer
 
int myvar = 5; int * ptr = & myvar; int & rfr = myvar; void funS(int Spar){}; void funP(int * ...
[3 replies] Last: Thankyou guys yes this does help a lot I will figure out timely when i... (by danicpp)
Assigning Random Value
 
Hey guys, here is my issue. As shown in the code below, I'm using getline, and stringstream to assig...
[6 replies] Last: No worries, we've all been there! Ha (by ColtonBoyd)
Interesting use of auto to make a foreach macro
 
I thought I'd display my fun use of the new C++11 auto keyword to create a compile time foreach. I...
[2 replies] Last: Oh snap! (by flamewave000)
by bw119
outputting a partially filled array onto a text file
 
I have a partially filled array and I want to put that into a text file. Say I don't know how partia...
[1 reply] : You're going to have to determine how many entries are in the array. ... (by AbstractionAnon)
Initializing static member just once throughout
 
Here I'm trying to initialize PersonFactory::ethnicSurnames just once for the entire run of the prog...
[5 replies] Last: What I meant was if it was initialized outside the class as: const... (by prestokeys)
by LMUZZY
Need better understanding + need to solve an error.
 
I'm learning C++ off of this very website, and i'm up to this section : http://www.learncpp.com/cpp-...
[4 replies] Last: Thanks, got it working perfect now =D (by LMUZZY)
Pages: 1... 2930313233... 50
  Archived months: [jun2014]

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