General C++ Programming - November 2011 (Page 39)

vectors
 
If I am using vectors and want to insert integers from 0, 999,999, and then find the elements with value 100,000 and lace an iterator to point to that element, ...
[2 replies] Last: If you're using Windows, the way to get the CPU time, rather than the ... (by andywestken)
What's the matter with my code?
 
I'm in a cpp class in high school, and I'm using what I've learned in there so far to try and make my own program without code samples. This isn't a required th...
[7 replies] Last: Moschops, the user is supposed to enter in the temp in fahrenheit, an... (by Moschops)
TAB SIZE PROBLEM
 
Hi, I have to make a program in c++ which reads a text file and prints it out.The tricky part is that when it reads 4 spaces in row it has to convert it to '\t...
[3 replies] Last: You are going the wrong way. Convert all tabs to spaces so that things... (by Duthomhas)
by Koak
CryptUnprotectData
 
I have included wincrypt.h but when I try to compile I get an error. `CryptUnprotectData' undeclared (first use this function) I am using bloodsheds Dev-C++...
[7 replies] Last: Alright, thanks. (by Koak)
irritating error
 
keep getting three errors from this line cout << nProduct << "\t"<<endl; void main () { // Declare a 10x10 array const int nNumRows = ...
[1 reply] : An array declared as a has elements in the range of a to a , a is o... (by kbw)
variance and mean
 
I have to output Mean and Variance, I can get output for Mean but not the Variance. Can you please look at my code and help me on how to input code for the Var...
[1 reply] : Why oh why don't you just have two functions called variance and mean ... (by kbw)
Netbeans IDE
 
I have a Mac Book Pro running Lion, and my IDE is Netbeans! When I run simple programs such as the following, I get red lines underneath saying cannot find fil...
[4 replies] Last: See this forum: http://stackoverflow.com/questions/6891841/trouble-us... (by spedison)
setting output width for values if a function
 
Okay, I have most of the code for this done, but something that I just can't get is how to separate the different values given out by a function. For example, I...
[2 replies] Last: of course. Here is the code I have written. I think the formatting pr... (by Ricardo R)
Problem about Davis Putman algorithm
 
INPUT.txt 6 p q r s k m 6 ~p|q ~q|r ~p|~r|s ~r|k ~k|m r m right OUTPUT.txt ~p|q,~q|r,~p|~r|s,~r|k,~k|m,r,~m p: Resolve unsuccessfully q: ~p|~r|s,~r|k,~k...
[no replies]
one more const problem !?
 
it says: "expression must be constant value" "can't create an array of size 0" int main() { const int* const var = new const int(30); int arr ; r...
[5 replies] Last: Ohh! lol off course :D thanx for clarification Syuf!! (by codekiddy)
const function ??
 
hi, I'm having dificulties understanding this function: #include <iostream> using namespace std; const int const f() { cout << "hello" << endl; r...
[5 replies] Last: @ceruleus thank you, I have been reading about that in my book :) tnx... (by codekiddy)
Please, help to choose the right way !
 
Hello, I want to learn serious programming, I have some experience and understanding of the basic stuff. Now, I want to begin REAL programming, but I am conf...
[6 replies] Last: Thanks a lot guys, I appreciate your advices I think that I will learn... (by crazy frag)
Passing 2D arrays between classes
 
Hi, I am having problems sharing a 2d array between to classes in c++ I have made software that takes data files for sensors and does various thing to the...
[2 replies] Last: WilliamW1979 is right .. past your code .. (by bluecoder)
by Walt
Help
 
Trying to learn C++ and I can't figure out how to fix the errors in this code. It's supposed to convert the int into a string and display the result. #includ...
[7 replies] Last: Its again conversion problem .. you need to use ostringstream , and is... (by bluecoder)
Class Name Before Scope Operator ?
 
template<class T> Pair<T>::Pair(T firstValue, T secondValue) { . . . Why the <T> is here ?What it's for ? Would love to have a simple and unde...
[4 replies] Last: Ahhh,it means that if <T> was replaced by int then only int is accepte... (by hentaiw)
Conditional Branches?
 
Anybody know much about these? id like to create a programn where you can say something for example: Programn: Are you okay? User: Yes If yes: Programn...
[4 replies] Last: Problem with switch statements is that you need to have an integer in ... (by WilliamW1979)
Problem with my code
 
I've been digging at this for a while, and I just can't quite figure out what I'm doing wrong. After staring at my code for about an hour, I decided to just see...
[3 replies] Last: #include <iostream> #include <cstdio> using namespace std; // n →... (by WilliamW1979)
Waiting for a process to end? [VS9 C++]
 
On my system there is an application (App.exe) that runs, but sometimes it terminates (gracefully and expectantly). At the same time I have another application ...
[1 reply] : Well, first you can get the instance of the app.exe by the title of th... (by WilliamW1979)
Help with sparse matrix in c++
 
In my cs2 class the assignment is to impliment a sparse matrix with pointers without using a 2d array. Here is the exact text: A sparse matrix can be repres...
[no replies]
Array of pointers to objects
 
I have to initialize an object of class Array, which private element is array of pointers to objects of class Message. I can't use <vector> or linked lists. But...
[4 replies] Last: I've meant something like this: class Array { Message** el; // or Me... (by stefaneli)
November 2011 Pages: 1... 3738394041... 47
  Archived months: [oct2011] [dec2011]

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