General C++ Programming - April 2013 (Page 26)

semop man page explanation
 
Hello all, Could someone explain what does this mean: · The calling process catches a signal: the value of semncnt is decre‐ mented and semo...
[no replies]
This is definitely a typo right?
 
This function from my book: // Comparing two CBox objects - ordinary function version bool Compare(CBox& box1, CBox& box2) { { return box1.Volume() > bo...
[3 replies] Last: Ok thanks @LB That looks really cool lol (by Anmol444)
Why wouldnt this work??? (1,2)
 
The Following in my book: " // Ex7_09.cpp // Initializing an object with an object of the same class #include <iostream> using std::cout; using std::endl; cl...
[20 replies] Last: Oh true thanks naraku9333 (by Anmol444)
What happens when you reassign a variable?
 
If I have an instance MyClass Object , already declared and initialized, and I write over it, Object = // different MyClass object , does the deconstructor ge...
[2 replies] Last: Answer: No. The destructor does not get called. (by closed account DEUX92yv)
by purvik
Help needed with error ASAP!!
 
#include<iostream> #include<string> #include<array> using namespace std; struct birth_date { int Day; int Month; int Year; }a,b; struct cu...
[1 reply] : Please use code tags when posting code here. For some reason, you've ... (by MikeyBoy)
array of strings - need help
 
hi I am new here I can't input array of strings (line 13). any ideas ?? it gives me runtime error on codeforces please help !! #include<iostream> #include<...
[2 replies] Last: You should read the description of scanf. You specified invalid argume... (by vlad from moscow)
Storing Words in .txt and reading them
 
I would like to store the titles of a CD and then read them. I have started a program but not sure how to display or make sure it is storing it in the .txt file...
[3 replies] Last: getline(cin, CD); should be getline(cin, input); ... (by Michaela Elise)
HELP!
 
1. Assume the definitions and initializations: char c = 'T', d = 'S'; char *p1 = &c; char *p2 = &d; char *p3; Assume further that the address of c is ...
[3 replies] Last: Does "all of the forums" include the tutorials? http://www.cplusplus.c... (by keskiverto)
Dijkstra's Algorithm?
 
void Dijkstra(int s,int t) { vertex *verts = findVertex(grid ); Heap H; for each(vertex *v in vertexList) { if(v->data == verts->data) ...
[2 replies] Last: help?? :O (by MMhawk607)
Help Outputting Data From File Into Structs and Arrays of Structs!
 
I am having a lot of trouble being able to get data from a file and input it into given structs and arrays of structs and then outputting the file. We are given...
[1 reply] : Missing the closing " on line 11 (by LB)
i need a manual solution for data structure and algorithsms
 
hi all :) i need a manual solution for this book: "Data Structures and Algorithms in C++ 2nd ed - M. Goodrich, et al., (Wiley, 2011) BBS" where can i fin...
[1 reply] : Post your answers to the questions on here and we can check them for y... (by closed account 18hRX9L8)
Convert number base 10 to number base x both contained a string.
 
How would you convert say "238273615237287352536266362524382737272" base 10 to a base x number contained within a string of characters?
[2 replies] Last: Here is a way to convert from bases. #include <stdio.h> #include <std... (by closed account 18hRX9L8)
by codder
unique_ptr and singleton
 
std::unique_ptr<A> a(new A()); If class A inherit from Singleton class and then I access with a->getSingleton().member(); it can be a problem? I mean, ...
[7 replies] Last: @ LB: A templated singleton parent class can be used to make child si... (by Disch)
output to console and log file
 
I have 18,000 lines of code that i would like to upgrade to include a log file. I want to replace the cout with a stream or something similar so that i can easi...
[9 replies] Last: > i ended up implementing the code in your other link. With the code ... (by JLBorges)
urgent help for c++ homework..
 
Hi, Im new here.i need help about the boolean func. as a first step i wrote the below part. it actually at first check the length then the characters but the c...
[3 replies] Last: cout<<name<<", please enter the character set: "; cin>>chars; The... (by pogrady)
complete graph data structure
 
Hello I need help with building a complete graph from a file. The format in the file is as follows. [ vertex 1] [ x_coordinate 1] [ y_coordinate 1] [cityna...
[7 replies] Last: Hi Can someone give me some hints with building a complete graph from... (by SoftDisk)
Getline() for vector<strings>
 
I am attempting to work an print a getline code for example... //Don't worry about the #includes and int main(). I am good enough at this to know the star...
[5 replies] Last: For each line, you need to getline into a string and push the stri... (by LB)
by Alam
Radix sort
 
Can anybody tell me why we use radix sort. Any good example?????????????
[2 replies] Last: Hey!!! Thanx it reallly helped me..... (by Alam)
Encryption / Decryption
 
I will get right to the point. Am trying to encrypt a char Array with binary data. I am doing this as an learning experience and am not out to do something fa...
[6 replies] Last: When using encryption and decryption, it is much better to use tried a... (by ajh32)
Segmentation fault problem
 
Hello I am recieving segmentation faults. #include <iostream> #include <iomanip> #include <ctime> #include <cstdlib> using namespace std; const int NUM_SIZES ...
[17 replies] Last: Well I placed 5 there because, according to the algorithm I'm followin... (by GreyOwl)
April 2013 Pages: 1... 2425262728... 53
  Archived months: [mar2013] [may2013]

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