Beginners - April 2012 (Page 62)

.txt elements into an array
 
hi, I have a .txt file something like this: comics shona 91765 0 0 China name 97245 0 ...
[4 replies] Last: You could use a vector of strings to automatically dynamically allocat... (by Stewbond)
by Owain
Array of function pointers
 
Hello. For my program, I need to write an array of function pointers which return the same data type...
[1 reply] : Two ideas come to my mind: 1. Make the functions take a void pointe... (by kooth)
operator
 
What is the difference between return_type operator SYMBOL (argument) and return_type &operato...
[3 replies] Last: Frankly speaking, there only difference is that in first case you will... (by Beju)
Loop issues
 
This is homework, so please, NO CODE. If you can just tell me what areas to concentrate on fixing. ...
[11 replies] Last: Just wanted to say that I got this to work after the first negative nu... (by badkaykay)
by Beju
How to correctly cast pointer to integer in C++
 
Hi, I was just wondering if there's a C++ way to make unsigned integer from pointer to any type. The...
[2 replies] Last: Thank you:) I thought that reinterpret_cast works only with pointers, ... (by Beju)
why wont anything display?
 
I am reading 2 .txt files into my constructor. Library::Library(ifstream& inbookfile, ifstream& ...
[6 replies] Last: Yeaaa, sorry about that, the .txt file actually doesn't contain "//isb... (by noonmoon)
How to use global variables in inline functions ?
 
Hi all, I have declared global variables in the main file. Then in other files where I need it, I...
[10 replies] Last: Thanks vlad. Wouldn't have been better for the compiler to have a homo... (by lalebarde)
copy constructor
 
class P { public: P() {} ~P() {} P(P const & p) { //<--- Question 1 ...
[8 replies] Last: C++ is just very strict about the type if you tell it that you will... (by Danishx83)
Create a program that checks whether or not a sentence is a palindrome
 
This is my simple program. However, I'm not getting correct results.. void main() { cout<<"Enter th...
[no replies]
How to approach problem
 
I'm given an array that holds information of flights origins and destinations, I am trying to write ...
[3 replies] Last: Dijkstra's Algorithm is based mainly around distance between nodes yes... (by Tikatee)
Random numbers: No repeats
 
I'm attempting to fill an array of size 200 with random numbers between 1 and 1000 but I can have no...
[19 replies] Last: Thank you! Works now:) (by NerdTastic)
Little help with code.
 
Basically I'm trying to copy a file from one place to another but I want the user to be able to chan...
[1 reply] : I guess that you could use $HOME ( %HOMEPATH% or %USERNAME% ) There is... (by ne555)
Could someone explain me what is Inline function and what does it do?
 
I was reading the C++ fAQ book and in chapter 9 the book starts talking about inline functions. The ...
[4 replies] Last: Almost. The compiler would likely inline it to something like this as... (by Disch)
Is this an acceptable style?
 
From feedback I have received in the past, I have been trying to move away from having 'magic' value...
[2 replies] Last: Consider using an enum to specify the type of containment. It makes th... (by JLBorges)
Here's a dumb question for you
 
What's the point of "const char * whatever;" Or the point of char *'s at all really. Isn't a char...
[19 replies] Last: Got it, thank you very much! (by NerdTastic)
how to SQL Query a csv file in C++
 
I'm not sure if this is the right place to put but any advice is helpful. I'm trying to write...
[no replies]
Self-deleting pointer class
 
I'm trying to create suicidal pointer. This doesn't have any particular purpose, because it delete ...
[5 replies] Last: @vlad Yes that might fix the problem, however, I wanted both pointers ... (by closed account 10oTURfi)
Compile error with global variable.
 
Hello, I'm trying to declare a global map like this: // These work as they should ALLEGRO_DISPL...
[13 replies] Last: Happens :) Please mark the question as solved. (by TheDestroyer)
Guessing game
 
Hi everyone. I'm trying to make a guessing game or well I have made a guessing game between a human ...
[10 replies] Last: Sure. I don't know if I'm the best to be learning from since I'm also ... (by doddolfur)
Best ways to do profiling??
 
What are the best ways to do profilling? I kind of new to the thing yet I've got an assignment req...
[1 reply] : What kind of profiling are you talking about? please be specific and e... (by TheDestroyer)
April 2012 Pages: 1... 6061626364... 66
  Archived months: [mar2012] [may2012]

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