Beginners - November 2008 (Page 6)

by Nay
Reading from and writing to text files
 
Can anyone guide me how to take input from a text file and then send the output to text file while working with STL..
[2 replies] Last: Take a look at the relevant section of the tutorial on this site, it c... (by Faldrax)
Loop to Populate an Array and Then a Loop to Display the Array
 
I've used this loop before. It is supposed to count up to whatever number I enter. All of a sudden, the output stops at 6.I enter 1. The program returns 1. Two?...
[7 replies] Last: Glad for you killingthemonkey! wish you good luck with your c++... (by arun1390)
by sacred
How do I output an address in a vector? Instead of its contents...
 
Hi. I've got a short bit of code and what I'm trying to do is read from a text file using getline. I would like to get the line number of a word when looping ...
[2 replies] Last: That's cool! I didn't know about that one... (by seymore15074)
unknown statement
 
hi together, in a source code i found the following: bool Logger::Success(const char* msg) { return !! LogSuccess(LogObj, msg) } So what ist ...
[2 replies] Last: And it's totally pointless in this case since Logger::Success() return... (by jsmith)
by Bernie
fork()
 
Hello I am new to this forum and new to C I am having trouble understanding fork() process and threads, in relation to building a simple webserver. I would l...
[2 replies] Last: Thanks! (by Bernie)
how to creat a highscores database at VS c++
 
ei dudes.im a newbie on this prog and im just wondering if it is possible to create a high scores chart at my program co'z i have this proj for the subj, and i ...
[1 reply] : Do you want a container? http://www.cplusplus.com/reference/stl/ (by Bazzy)
Quick SDL Release Error Question
 
Hey guys, just finding out if there are any reason why my game builds fine using SDL with /SDL_image/SDL_h. Basically I can build it in debug mode game works pe...
[2 replies] Last: What do the linker errors say?? (by guestgulkan)
Linked list problems
 
Could someone please tell me what is wrong with my code. // poddriver.cpp //Adapted from Roger Priebe //CS2308 11/17/08 #include <stdlib.h> #include...
[6 replies] Last: Just reading through that int BobCatPod::addSong(Song s) function... (by guestgulkan)
What is wrong with my code?
 
#include <iostream> #include <fstream> #include <string> #include <cstdlib> #include <ctime> using namespace std; string make_Stars(int num_Of_S...
[11 replies] Last: the only problem now is turning the * into the char value the user put... (by cplusplusnoob)
.length() equivalent for char array
 
I have a char myArray that I'm passing to a function. In my function I need to capture the length of the array similar to how length() returns the number of c...
[2 replies] Last: int strlen(char*) was exactly what I was looking for. Thanks! (by Return 0)
trying to add numbers using functions.
 
I just need a little help this is something i dont think is too complicated. I am using borland turbo c++. I am going to have three functions; total, add and...
[4 replies] Last: thanks, i will look harder (by ineedinfo)
Anyone fancy being a mentor...Please!
 
im a complete beginner and need some one to help me get on my feet so i can learn to the best of my ability....please help
[2 replies] Last: http://cplusplus.com is a great place to learn for the absolute beginn... (by ebarroga)
I'm new to strings...
 
void sortWords(char wordList , int wordCounts , int numWords) { int i, j; int min, temp; char *k; for (i = 0; i < numWords-1; i++) { ...
[1 reply] : Arrays and pointers in this case aren't the same thing. You are attem... (by jsmith)
How do I plot?
 
Can any one give me a simple example to plot a 2-d graph? I need x-axis and y-axis to plot a vector of stock prices and a vector of time.
[1 reply] : The easiest way is to store your output in a .csv file using DOS (if y... (by Scipio)
advices
 
i am a class 11 student in india. i am interested in robotics. so i want to make a basic robot for my forthcoming project. could anyone suggest me , what all ...
[1 reply] : google. This isn't a robotics or electrical engineering forum. (by Zaita)
by Schouf
How to read a filename and made a list
 
Hi everyone. I'm a newbie in C++ program. My problem is: I need to search filenames with a part of them, and made a list of them. For example, I have these ...
[1 reply] : If you have the file names in std::strings, you can use the member fun... (by firedraco)
How to copy the first char of a string to a char?
 
This is a very simple election program for my c++ class, I need to write the votes on a txt file after that I need to read the file and count the votes and I do...
[1 reply] : Get rid of strcpy( vote, line ) and your if()s need to be if( line.... (by jsmith)
Multiple Definitions error
 
So I get this nasty multiple definitions error when I compile my program with g++. The program uses two classes, cbt (complete binary tree), and node which are...
[6 replies] Last: Yup, remove #include "tree.cpp" and it will work. EDIT: never #incl... (by jsmith)
How to compile in gedit?
 
Last week i learned about c++ i'm using Arch linux with the program Gedit and root-terminal i made some condes but dont know how to cimpile it and "play" it, ...
[2 replies] Last: hokay! thnx man! :D (by Thorgil)
windows class size limit?
 
I made a class, which need to have 16-17 variables in its private or protected section. Problem is, when I put in more than 14 variables, it compiles okay, but ...
[17 replies] Last: I wrote a copy constructor for the AI and for dot . It seems to be wo... (by gregnnm)
November 2008 Pages: 1... 45678... 19
  Archived months: [oct2008] [dec2008]

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