Beginners - July 2010 (Page 27)

put pointer problem
 
i was reading and writing from/to a binary file iwas making tellp() as a check when i find that at some times it gives me -1 so what does it mean? and by the...
[1 reply] : a return value of -1 by tellp() probably means that file stream is not... (by spaggy)
question about read, write I/O streams
 
hi everybody i was just having such a frustrating question concerning using read and write of I/O streams. here is the code: #include <cstdlib> #include...
[2 replies] Last: There are a couple weird things here: 1) http://cplusplus.com/refer... (by Zero One)
by c0y454
placing void() in a 2nd source file
 
HI, im trying to create a program that contains a void() function which is in a second source file. Its supposed to look like this: File 1: ... int ...
[1 reply] : Try to see if this article helps you: http://www.cplusplus.com/forum/a... (by Bazzy)
initialising an array within a class using a constructor
 
Hello, i would like a class to contain an array of strings ,see below class book { public : book( string auth ); private: string author } ho...
[1 reply] : That syntax won't work with current standards. You'll need to do some... (by Bazzy)
Writing makefile for a c++ project
 
Hi all, I'm Andrea, an Italian student of computer science. I need to run a project in a server via ssh, so I need to write a makefile (I working on Eclipse no...
[4 replies] Last: Thanks, I separate include path and libs and now working good! (by guess85)
Can someone explain this character array code to me?
 
I'm a self-taught programmer and I've been going over this part for 4 days now and I just can't get the hang of it. It doesn't seem useful and it doesn't make s...
[8 replies] Last: Yeah I understand arrays, just this bit's been buggin me. I'll just pi... (by Soap360)
Calculate average using nested loop
 
I am a newbie in C++ programming language.I have no idea for this question.Can anyone teach me or give me some idea about this question.Thanks.This is the quest...
[1 reply] : Show us what you've done so far and where you are having troubles. (by Zhuge)
declared enum "does not name a type"
 
I have several enums declared. I then have several classes declared, all of which use these enums. When I compile, I get an error with one of the enums, calle...
[4 replies] Last: You really should rename it "enums.hpp" as firedraco and Athar have sa... (by Zhuge)
About auto_ptr
 
I have a function of which return type is an auto_ptr, i have no idea what i should return if user input an invalid parameter. auto_ptr<MyClass>& myFunction(...
[6 replies] Last: Thanks all guys, for your replies. Fortunately, i needn't to change m... (by aidyszh)
finding out an armstrong number
 
hi.. i was doing the exercise from ..a website.. I managed to write the code..to find the armstrong number...but the question is actually under the nested loo...
[5 replies] Last: so..it makes sense..what I did rite...thanks..and also for the tips on... (by kalp1200)
Invert a character array.
 
Hello, So I found this exercise in the book I'm currently reading; Create a function that will invert (translating this on the fly - basically just switch...
[4 replies] Last: Ah, that's exactly what I was looking for, it makes sense now! Than... (by AngelHoof)
size while writing a structure
 
i was writinga structure to a file and i tried to calculate the size of the member varibles and then the size of the object of that structue and ifound out that...
[4 replies] Last: http://en.wikipedia.org/wiki/Data_structure_alignment#Data_structure_p... (by Zhuge)
by vlad61
do {} while question (User==gulible)
 
#include <iostream> using namespace std; // So the program can see cout and endl int main() { int x=0, j=1; do { cout<<"Enter any number ...
[6 replies] Last: Thank you very much for all the in depth explanations. I completely un... (by vlad61)
can somebody please explain this c++ shirt
 
http://www.thinkgeek.com/tshirts-apparel/unisex/itdepartment/9a0e/
[14 replies] Last: ok nice that's what i was thinking thanks a lot ^ (by whitesnow)
a very simple question about visual c++
 
hi, i'm using visual c++ express 2008. i have built a project called helloworld. under this project i created a source file, it contains code which writes "he...
[7 replies] Last: what is the use of multiple source files under same project? Organiza... (by helios)
by vkaul1
are these warnings in visual studio to be taken seriously
 
I get these 43 warnings in compilation of my code. I hope it is ok. How to suppress these warnings C4786 if they are not that harmful. F:\WD_Windows_Tools...
[1 reply] : try using #pragma warning(disable:4786) (by guestgulkan)
Code check
 
Can someone advise where im going wrong with the below code?? #include<fstream.h> #include<string.h> #include<conio.h> #include<stdlib.h> #include<ti...
[9 replies] Last: Hi RyanCaywood Thanks, I will have a look at this (by Wakesta)
by keithh
Character String (1,2)
 
Is this the proper way to put a floating number in an array? char s ; sprintf(s,"%4.1f",winpercent*100.0);
[24 replies] Last: got it. whew. thanks all. (by keithh)
Guess the number
 
Just made a CMD guess the number game, would like some constructive criticism or evaluation. Thanks in advance, Actionman1995 #include <cstdlib> #include ...
[3 replies] Last: Avoid sing namespace std; , http://www.parashift.com/c++-faq-lite/cod... (by Galik)
Text Editor
 
Hi . I need some information about create text editor in c++ with linked list , and file(i/o stream).
[1 reply] : what? http://www.cplusplus.com/articles/how_to_ask/ (by Bazzy)
July 2010 Pages: 1... 2526272829... 31
  Archived months: [jun2010] [aug2010]

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