General C++ Programming - November 2009 (Page 8)

Reading files into ARRAYS
 
OK heres my problem Im trying to Read a file into an array. My data file looks like this ...
[1 reply] : there is no problem in this, you have to paste some more code. are you... (by writetonsharma)
by netP
Nested "include"???
 
Hi, I am confused of how to use nested "include"s, since I wrote some and g++ gave me several e...
[4 replies] Last: Thanks, Disch! That helps! I changed the include statement to forward-... (by netP)
Exceptions and IF
 
Well, I can't see why(or when) should we use exceptions instead of the if statement. Other than catc...
[11 replies] Last: 1 - The function itself. (by Disch)
How to check the keyboard without stopping? (1,2)
 
Is there a way in C++ to check if a key has been pressed without stopping the program? E.g.: wh...
[20 replies] Last: Boost has everything. It's almost annoying. (by chrisname)
Having problems getting information to file
 
This program is designed to anylize any character put into it from an input file as a letter,(capita...
[5 replies] Last: Alright thanks. No we have not covered globals yet in class, so I thin... (by ralph26)
by Null
Question about "operator new"
 
Hello, just a quick question about new With new it's clear. E.g. char *c=new char ; // alloc...
[2 replies] Last: Almost the same. new T should be deleted with delete , but new T shou... (by helios)
Is the STL string class thread safe?
 
Just wondering if anyone knows if the string class in the STL is thread safe? And if so, around what...
[2 replies] Last: Just to add... I know of no STL string implementations that are thread... (by jsmith)
Vector user-defined search function!
 
Hi I've been trying to figure this out for hours now and I can't get it so I thought I'd ask the gen...
[2 replies] Last: search() does not return anything in particular if the loop does not r... (by jsmith)
invalid operands of types int and float to binary operator <<
 
Okay, so the program works until I add the last part on and then I get this error message: invalid o...
[3 replies] Last: You have to pass them as parameters to the function. BTW, just a wo... (by jsmith)
wrapper function for new
 
Hi Guys, Actually, when we allocate memory using new we do it something like struct nod...
[5 replies] Last: I wouldn't even bother trying to catch bad_alloc as the result of an O... (by jsmith)
by fabio
bcc and makefile
 
Hello, I'm trying to compile a little project with the borland command line tools 5.5. I'm using ...
[4 replies] Last: If you're using bcc, and you have a make file that works, you'll find ... (by kbw)
c++ with databases like mysql/sqlite3
 
Hi Friends, Pls Kindly Help me. Thanks in Advance. When i tried to Connect c++ ...
[2 replies] Last: If you want to use sqlite3, download the amalgamated source from the s... (by kbw)
need a way to find and either replace or delete text from a text file
 
to start with, sorry about the length of the title, i rewrote the title 3 times and that was the sho...
[11 replies] Last: Galik, that is neat! thank you. your stuff works even when there is... (by herbert1910)
by mnunez
Amicable numbers 2
 
int main() { int low; int high; //range cout << "input the start of the range: " << endl...
[1 reply] : Please put your code in code tags. This line: amicNums (int low... (by Disch)
by mnunez
Amicable numbers
 
bool isAmicable(int start, int end)//you want to give it a range, but to check we need an actual num...
[1 reply] : Please put your code in [co de][/co de] tags. Please tell us what... (by Disch)
by jrohde
Using OpenGL in VC++
 
Hello all, I was having issues with OpenGL in VC++, so I created the following simple test files ...
[3 replies] Last: Thank you. That appears to have done it. Problem solved. (by jrohde)
map access outside class
 
Hi All, I'm new to C++. I need some help regarding the usage of map STL container. I've declare map...
[5 replies] Last: Thanks kwb, it is very helpful ..... (by gauravkr)
by c51
combining file open statement and declaration?
 
Isn't this how one would combine the declaration and open statement for a file ? ofstream fou...
[1 reply] : No. There are two methods(from what I know, might be wrong): ofs... (by mcleano)
pointer question
 
Consider the following code: char s = "Hello"; const char* pc = s; // pointer to constant pc ...
[5 replies] Last: The fact that you can change a const object using the const cast. You... (by helios)
Is it possible to loop a switch?
 
I'm writing a program and I'm wondering if it's possible to loop a switch because my program is supp...
[2 replies] Last: @OP Don't double post: http://www.cplusplus.com/forum/windows/16404/ (by Bazzy)
November 2009 Pages: 1... 678910... 16
  Archived months: [oct2009] [dec2009]

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