General C++ Programming - May 2009 (Page 4)

i need example of a different stack template
 
I have a source code of a stack which inserts elements and delets the elements that are at the end of the stack : #ifndef TEST_TSTACK1_H #define TEST_TST...
[5 replies] Last: i need make a program which manages the students of a group in an univ... (by piulitza)
#pragma comment
 
As many of you know, #pragma is a compiler specific macro. #pragma comment allows the user to send messages to the compiler at compile-time. My problem is...
[6 replies] Last: It's purposely undefined to let compiler vendors use it for whatever t... (by helios)
To erase specifice element in the Vector
 
Hi, Dear all, On each iteration in Vector , i want to deduce one element and delete it. then pass remaining vector to my function. so, problem is this. i...
[6 replies] Last: Thanks Hammurabi, it is solved. (by amanyasin)
Put a variable value inside a Compiler Directives
 
Hi, Good Morning! I want to print a variable value inside a preprocessor directive! E.g.: #define D(value) value main(){ char test = "testing"; ...
[3 replies] Last: #include <iostream> #define D(value) { std::cout << #value "=" <... (by kbw)
My second assignment about Linked Lists
 
Hey there, I have wrote code for my second assignment. There is txt file with employe department code number name and age. I need to read data from txt file ...
[1 reply] : Can you please format your code. It's impossible to read otherwise. (by kbw)
by Adalte
A problem with Nodes
 
Hi! Please, it's very important for me to solve this problem. I'm very grateful for all hints, proposition or h e l p I can get. Thank You in advance. Th...
[1 reply] : Have you written anything? I don't see a Shape class or a double thre... (by kbw)
by nanger
about the comand line arguments of main function
 
I want to run my program using the command line arguments of main function like this: ./p2ptv PeerBandwidths={{0.271,0.2,INF},{0.661,0.35,INF},{0.0691,3.5...
[4 replies] Last: yes,you reminded me that the quotes I used are in another format. I'... (by nanger)
by Maze
Timestamp in millisecond to UTC
 
Hello, I want to convert a Timestamp (received from a NI board) to t_date format. The timestamp in milliseconds is store in 2 long variables (TimestampLSB...
[2 replies] Last: Sorry I did a mistake ! I want my timestamp into a struct tm. (by Maze)
Standard Deviation
 
My program currently displays the mean and standard deviation of student marks. However, by default (since there are 2 records already with marks of 66 and 78.5...
[3 replies] Last: sorry I forgot to mention that the function I posted is a cut-off from... (by lebronjames)
Getting junk characters while using fgets to read from file
 
Dear All, I am using fgets to read line by line from file. There are some special characters in the file like degrees and micro symbols. After reading usin...
[4 replies] Last: It isn't a junk character -- it is a code page mismatch. MS has a b... (by Duthomhas)
Opening and writing to file using binary mode.
 
Hello. Well, my problem is, I'm having a lot of trouble opening a file in binary mode. Yes, I have looked for the answer to my problem, but come up short,...
[11 replies] Last: If you want to store a 2-byte word, you need to write it one byte at a... (by Duthomhas)
include multiple files in project
 
For the life of me I cannot get my project to compile when I split it up into a few different files. Here's some sample code of my problem (Which lies in a glob...
[5 replies] Last: The best use of global data is to keep information that is not directl... (by helios)
Convert string in pentadecimal to int
 
ok... You may have seen my other thread about the reverse. (jdd, thanks for the help, and sorry I didn't reply to that. It helped a lot though.) If not, look ...
[1 reply] : The idea is to isolate each digit and convert one digit at a time. ... (by Disch)
AVL
 
#include <iostream.h> #include "llstack.cpp" #include <conio.h> template<class T> struct Node { int rh; int lh; Node<T> *left; Node<T> *right;...
[no replies]
by Joe123
Removing a pointer from the centre of a vector
 
Is there a better way to remove something from the middle (well, a general position) of a vector than this: void RemoveSprite(int ref){ delete SpriteList ; ...
[2 replies] Last: Oh, I didn't realise you could just add an integer on to the iterator ... (by Joe123)
Inserting date and time for computer
 
I am working on a "Class" program that involves the entry of the date and time. Is there a way to call the current date and time from the computer and display t...
[1 reply] : http://cplusplus.com/reference/clibrary/ctime/ (by Warnis)
How..Complicated reading problem
 
My data.txt contents is like this: 3 6 8 12 60 74 57 94 13 --------------------------------- This is my code to read it and store it: int ...
[2 replies] Last: Thanks for the idea..I found the solutions #include <iostream> #in... (by alan6096)
by gretty
Read a Text file & store it in a Data Structure
 
Hi :) How do you write a program that reads a text file (music.txt) & stores it in a Data Structure. I am a novice learning over the internet so I this is...
[2 replies] Last: http://www.devarticles.com/c/a/Cplusplus/Serialize-Your-Class-into-Str... (by Duthomhas)
by GalaG
C++ oracle question
 
I've been trying for a few months to connect to Oracle through c++ using mingw on windownsXP (using Code::Blocks as IDE). sadly Oracle OCI/OCCI don't suppo...
[5 replies] Last: Thanks all, both OTL and SGBD look promising, thanks for help, ... (by GalaG)
No Headers
 
Is it possible to create a program without any C/C++ Headers. I had asked this question before also but got all answers like to look at linux source code.I don...
[11 replies] Last: Thanks folks. (by Denis)
May 2009 Pages: 123456... 17
  Archived months: [apr2009] [jun2009]

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