General C++ Programming - October 2014 (Page 3)

problem with recursive definitions
 
Hello wise C++ forum, I'm aware that "ordinary" recursive definitions are allowed in C++, the most typical example being a factorial: fact(x)=x*fact(x-1) wit...
[2 replies] Last: Thanks very much coder777, this isn't the first time you bailed me out... (by STxAxTIC)
Class constructors and data member initialization
 
I recently discovered the new - new to me anyway! - feature of modern C++ that allows you to set the initial value of a data member when you declare it: cla...
[16 replies] Last: keskiverto, that's a great little link. Cheers. (by mutexe)
Problem with Strings
 
I am supposed to be writing a program for class, but I am having trouble with a string. Here is the code so far: //Todd Dunaway //10/30/2014 //Chapter 4: If...
[2 replies] Last: Thank you, I did not notice that. (by TheUnholy)
Running C++ Program on C# Tool
 
Hi, There's a tool (with GUI) which was built in C#. Additionally, I have a C++ script. Is it possible to have the C# tool running the C++ Script. For...
[3 replies] Last: Sure there is, you of course will need access to the source code of th... (by Z e r e o)
by yo2xia
P value from lffff function in C++
 
I am beginner of C++, any help will be appreciated. #include "stdio.h" #include "lffff.c" #include "lbeta.c" #include "lgaml.c" #include <iostream> using...
[2 replies] Last: thank you, I have got it. (by yo2xia)
by yo2xia
P-value calculation is not exact via F distribution in C++
 
New code in C++, no precision error. share it with you! //*---*---*---*---*---*---*---*---*---*---*---*---*---*---*---*---*---* //*---*---*---*P-value for c...
[4 replies] Last: Sorry, I am late to reply you. And this is the code with no problem, s... (by yo2xia)
by ostar2
Zlib outputting blank file
 
Hello, I wrote a program to compress a file with gzip, which works fine. I also wrote a program to decompress the gzip file, which runs but outputs a blank file...
[4 replies] Last: I would like to decompress the file into a buffer but it is becoming f... (by ostar2)
Function stuck
 
I've written some code to randomly generate probabilities: int Queue::car_per_hr() { srand( time( NULL )); int prob = rand() % + 101; // Probabilit...
[3 replies] Last: Ye used srand in my int main instead of calling it everytime car_per_h... (by JudyFaye)
by yo2xia
how do I find the pivots of my matrix
 
I want to get non-singular matrix with the C++ linear algebra library eigen, but I do not know which function works, any help will be very appreciated. assum...
[5 replies] Last: @Duoas So good answer. thank you! (by yo2xia)
by NQS
Problem with server in client-server program
 
I am doing a server-client program in C++ and am having trouble figuring out how to do a couple of things. I already have the server and client up and running a...
[4 replies] Last: I am still at a loss on how I can send the results that I need to sen... (by kbw)
Linked list remove node...I am banging my head!!
 
pls help me. how to remove node from linked list. I am trying to implement this in a file record to remove data from struct..I dont know how addressing in linke...
[11 replies] Last: thanks..data structure is new to me (by csstudent123)
by roarkr
Timer Callback
 
Hi, I hope someone can help me out here. Either with a correction to existing code or a new way of implementing a "double push" function. I have a button ...
[1 reply] : No replly. I though this was an expert forum (by roarkr)
Creating a Loop for Arrays
 
Problem: I am using a method to pull account ids from an account.txt file. I'm able to get the code to work as long as the input is valid (i.e. the person ...
[no replies]
by S33ds
Would it be quicker to use a binary heap to get the top x amount of integers from an array or use quick sort
 
To get the highest X amount of integers from an array, do you guys think that using a binary heap like this would be quicker: binary heap to get the high...
[3 replies] Last: That doesn't answer my question It actually does. It states that nth... (by MiiNiPaa)
Reading in and initializind data from file
 
Im familiar with fstream and know how to read in data, given that there is one type per line. But I have a file that has multiple lines each containing a str...
[1 reply] : #include <fstream> #include <iostream> #include <sstream> int main() ... (by SreeB)
i need help ????
 
hello please can anyone help me on how to solve this program ?? Create a text file that contains student number (9-digit number), year (one of the four ye...
[1 reply] : Please note, that this is not a homework site. We won't do your homewo... (by keskiverto)
GUI with C++
 
Hi, I'd like to build a simple GUI to work with my C++ program, on Windows. I understand that VS removed the Win Forms from the CLR tab in C++. How the...
[1 reply] : I would recommend a nice, rich cross platform library like QT. http:... (by tmason)
help, program crash when it's returning an object by extract funciton
 
while(!secList.empty()){ Security se = Security(); se = secList.extract(); // CRASH cout << "Security info: " << se.security << endl; cout << "Transa...
[4 replies] Last: what do you mean slist == 0, do you mean ssize == 0? Yes. Surely, th... (by kbw)
& symbol (1,2,3,4,5)
 
Hello. Please explain to me the various different meanings and uses of &
[86 replies] Last: MinipAA wrote: & is context-dependend token If you see & as binary op... (by csstudent123)
SDL2 help
 
I want to do 2d programming with SDL2 but i cant find any good tutorials. I want to find a tutorial on setting up SDL2 in microsoft visual studio 2013 and one ...
[2 replies] Last: Try these: http://lazyfoo.net/SDL_tutorials/ -SDL 1.2, c-ish, but... (by rjvc)
October 2014 Pages: 12345... 38
  Archived months: [sep2014] [nov2014]

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