Beginners - February 2009 (Page 9)

What is wrong with this?
 
Please see 4th postfor information. (3rd reply)
[10 replies] Last: Just adding that in c++ vectors are better containers than using an ar... (by youknowme)
Outputting on multiple lines
 
I wrote a program that prompts the user to enter a four digit positive integer. What I need is the program to output the four digit integer one digit on one li...
[6 replies] Last: maliks book (by gobills)
multiple comparisons
 
In comparing four numbers, is there a simple way to determine which number is the smallest? I'd rather not do a series of if/then statements... Thanks!
[4 replies] Last: min() won't do it then. You need more logic to detect and deal with t... (by jsmith)
array of pointers to characters
 
Hey, I've found something strange about of arrays of pointers to characters. const char* a ={"test1","test2"} a prints out "test1", and a "test2". ...
[7 replies] Last: Thanks for all your help, really! (by nicolasfranck)
Counting vowels and consonants
 
I am trying to write a program that counts the number of vowels and consonants from user input. I also would like to count the number of words and lines from th...
[1 reply] : The following code does what I think you are trying to achieve, heavil... (by chris)
Template question
 
Hi everyone, I have two questions about the use of a template declaration. This is the code: using namespace std; template <typename DataType> cla...
[2 replies] Last: http://www.cplusplus.com/doc/tutorial/templates.html (by closed account z05DSL3A)
How to use Memo1 in a function
 
Hi everyone! I'm trying to use Memo1 (as an text output on a Form) in a function. But it won't work. I get this Error:[C++ Error] Unit1.cpp(43): E2451 Unde...
[5 replies] Last: Yes! thank you, it's working! (by Espresso)
by Atrus
Strange error on lines .text+0x220
 
I'm going to appologise in advance for posting so much. But, I have no idea where the error actually is so, sorry... When I attempt to compile, I get these ...
[5 replies] Last: To compile several files as one executable: g++ a.cpp b.cpp c.cpp -o... (by helios)
creating a file
 
I want to open a file for a fstream-object and i want the file to be created if it doesn't exist yet. This one works: std::fstream mystream; mystream.open...
[3 replies] Last: I believe that std::ios::app will add onto the file if it exists or ... (by eker676)
While loop being skipped
 
This is a homework assignment for my CS class. The program basically reads lines of data from a file and calculates averages. I am attempting to go a little bit...
[2 replies] Last: instead of saying seekg(0), try seekg(ios::beg) (by athlete501)
wat is an expression
 
"#include<iostream> is not a regular code lines with expressions"wat is an expression in this case.
[6 replies] Last: Spaces don't matter: # include <iostream> ... (by Bazzy)
New to C++
 
I just got into C++ because its a class im required to take for my degree. I found this site and was fortunate to see that everyone here is pretty friendly with...
[1 reply] : Welcome :) (by Scipio)
change text color,font
 
what is the syntax for changing the text color and font. which is the header file required for this.
[1 reply] : Look at this snippet. (It's windows only though) http://www.dreaminco... (by eker676)
Warning Message
 
Could someone help me with this? This is the warning message http://s5.tinypic.com/28ilonq.jpg Variables http://s5.tinypic.com/n1a5fk.jpg I know it...
[2 replies] Last: Oh, I just put the .9999 there so it would round up the value I would ... (by GuraKid)
Palindrome/Read backward
 
I have to create a palindrome program that uses input and output files. I have to read in 30 names out of the 30 names 4 has to be palindrome and they must begi...
[1 reply] : You should open a file then check if it is not eof! That's the only... (by hannad)
create a linked list of nodes
 
Hi everyone! I need to implement a linked list for representing a (planar) graph with the particularity that nodes can only be added and not removed. After i...
[6 replies] Last: Hi kbw, I don't understand it exactly. When I have an adjacency lis... (by Espresso)
ofstream problem
 
I'm having a problem with the ofstream aspect of a c++ program. I have a rather large text file (1.9GB...ouch) that I'm trying to open with my program, do stuf...
[4 replies] Last: I'm just glad that I realized it myself...I feel slightly less dumb th... (by Zachary)
uploading a txt file !!!!
 
i have been trying to upload a txt file . and it worked for the first time . but then i changed the text using notepad , not with the studio . but then it...
[10 replies] Last: http://cplusplus.com/forum/beginner/7853/ <--The link to my question (by awasteoflife)
by Ramiel
making the leap from java to c++
 
Hello all, As the topic says I'm very new to c++, but I have some experience with java. To start learning c++ I had the (not very original) idea of making a...
[3 replies] Last: I recently converted into the right faith (that being c++) from anothe... (by tition)
by aozi
rather new with c++ / writing data files
 
Im rather new with c++ but i have programing experience on c and Java so that not a problem for me, tha main issue is now my professor wants me to work on li...
[1 reply] : If you don't use external libraries a C++ program works the same on Wi... (by Bazzy)
February 2009 Pages: 1... 7891011... 22
  Archived months: [jan2009] [mar2009]

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