General C++ Programming - February 2011 (Page 15)

calculate the summation of consecutive positive odd integers from 1 to n
 
Ok, so i am being a bit of an overachiever tonight, but I'm bored so what! I am doing my lab for next weeks classes tonight just for some fun but one exercis...
[4 replies] Last: Well, the sum of the first n positive odd integers is exactly equal to... (by jsmith)
Functor vs. Function
 
What's the difference between a functor, which has the purpose of storing states in-between function calls, and a function with static variables?
[2 replies] Last: "functor" has a very specific meaning -- it is an object that (optiona... (by jsmith)
by abakiz
Cin being Ignored in loop.
 
Basically this is a small part in a big program I've developed, I've managed to create an entire game of monopoly, now I've only got one error left... and it's ...
[2 replies] Last: u can get input in form of a string. get it checked whether it contain... (by satyamkrishna2004)
C++0x
 
hi, i'm a c++ noob and i've just started coding in c++(again, bc i had to finish some stuff with pascal @ school) and i've heard that the new c++ iso standard i...
[2 replies] Last: thank you so much for that answer :) (by subarde)
About the "^" sign
 
Hi, I have a piece of code that I am looking and I am seeing the " ^ " sign widely in that code. It is not used as an XOR operator by the way. It is used for v...
[2 replies] Last: thx (by shadowman)
How do you read from a file
 
Hey guys. I have a file with three names in it (first,middle,last) that I want to read from and display the full name. The problem though is that the word is no...
[3 replies] Last: If you must.. string getWord(ifstream& file){ string str; fi... (by hamsterman)
HOw to create a alphabetize list
 
hi guys. really nid some help.. we need to sort this names according to letters. aries beatrice catherine donny but acsully i dont have any idea of c...
[3 replies] Last: thanks for the reply . :) it helps :) (by ernandrew)
Creating a text document.
 
How would i take all the data from my c++ application and put it into a log file? or make a text document for it =D
[15 replies] Last: Ok... What I mean is this: int main(){ io rpgio("log.txt"); ... (by PiMaster)
vector::at question??
 
Ok I have a for loop that displays what's at position i in vector v2.However, I am getting the error "A reference of type "std::string &" (not const qualified) ...
[1 reply] : Shouldn't it be: template<typename T> T& Vector<T>::at( size_t ind... (by kbw)
Write a C++ program that solves quadratic equation to find its roots
 
Ok, so I am in my first c++ college course. I have done programming before in java, html, sql and some basic c++ stuff before. I find the class to be easy so fa...
[5 replies] Last: Got it to work great. Thanks again for all the help. And Liverpool ... (by LiverpoolFTW)
by Katma
School again
 
Hey guys, sorry, it's me again. This time I have a school assignment where we are supposed to find the weekday of a date, and whether it's a leap year. IE, "...
[1 reply] : Forget about parsing the input for now. Suppose you have three variabl... (by simeonz)
Overload?
 
I'm reading a C++ reference manual written by Bjarne Stroustrup. He listed all the keywords as most books do. I recognised all the keywords except for one: ove...
[4 replies] Last: The year was hidden; it was published in 1984 o_0 *Closes the PDF* So... (by closed account zb0S216C)
Checked Delete Idiom Question
 
I've been reading about a bunch of idioms in the past few days, and I have a question about the checked delete idiom. Below is how the site explains the code e...
[4 replies] Last: Alright, thanks for your time. (by closed account 3hM2Nwbp)
Critique my Work Hour Manager
 
This is one of my first projects but actually being useful to me. I would like some critic/advice on my project. Such as my coding style, how to make this more ...
[3 replies] Last: Also, I believe the word you mean is critique, not critic. I don't th... (by cppmatt)
Application Crashing
 
Hello, i am a major beginner to c++ but i know a few basic things so im trying to make something random. #include "stdafx.h" #include <iostream> #include ...
[3 replies] Last: Ty hamsterman, i watched a video tutorial on arrays and the only thing... (by KevinnTCG)
fstream
 
example abc // line 1 in textfile 123 // line 2 in textfile seekg(3) to point to 2nd line. however if abcdef // line 1 123 // line 2...
[1 reply] : Three choices come to mind: 1. If the file is never edited external... (by simeonz)
Need a split function!
 
Hello, I'm making a web crawler for my website. I've make the code which downloads the page done, It gives the code like this: Original file: <html> <he...
[4 replies] Last: THX man! You found the code i've been searching for! (by roelf01)
making a simple bot
 
ok, so i got bored today, and came across a really simply flash game: http://dagobah.net/flash/Cursor_Invisible.swf my question is: what would it require t...
[5 replies] Last: getpixel() doesn't return a location though.. so i wouldn't know where... (by jteally)
by bzz77
Problem reading delimited int data from text file using stream
 
I have text files that contain names and numerical data. I want to read both kinds of data into vectors. The code works for strings (produces a vector of stri...
[5 replies] Last: P.S.... If you or anyone else could suggest anything in my code that ... (by bzz77)
C++ Code Completion
 
Hi Everyone, I know this question has been asked before, but I think mine may be slightly specific. I have been hunting/comparing for the best c++ IDE out th...
[4 replies] Last: Another feature that I find interesting is on-the-fly syntax checks. I... (by simeonz)
February 2011 Pages: 1... 1314151617... 25
  Archived months: [jan2011] [mar2011]

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