General C++ Programming - October 2012 (Page 9)

defining 1D and 2D vectors and sending floats to them
How can i define a 1D and 2D vector and then send them floats?
Oct 26, 2012 at 11:55pm
[6 replies] Last: use at() function or simply do this with s as like arrays. (by majidkamali1370)
Problem with Text Files
Hi all. I am having some trouble with figuring out how to do something on my program. I am to create a program to read a certain file, and give its average. I ...
Oct 26, 2012 at 10:40pm
[2 replies] Last: Another option would be to open the file before you start your calcula... (by jlb)
Reading a data file with int16 short
I am trying translate a code from Matlab into C++. I am stuck at the most basic of steps: loading in a data file of int16. I know how to do it Matlab (its jus...
Oct 26, 2012 at 10:02pm
[3 replies] Last: Everything I do is a learning curve. You get used to always learning b... (by Duthomhas)
compiler
are there any free good compilers for c++ program for students. or is there any websites. can i write codes in editors
Oct 26, 2012 at 9:40pm
[1 reply] : You can download free MS VC++ 2012 Express Edition. Also you can use o... (by vlad from moscow)
structures
what does structures do in programming and how does it helps us struct database { int id_number; int age; float salary; }; int main() { data...
Oct 26, 2012 at 9:31pm
[1 reply] : http://www.cplusplus.com/forum/articles/40179/ (by cire)
pascal triangle
Write a program to compute the value of a given position in Pascal's Triangle (See image). The way to compute any given position's value is to add up the num...
Oct 26, 2012 at 9:29pm
[no replies]
challenge is my game
Write a program that, when run, will print out its source code. This source code, in turn, should compile and print out itself. (Fun fact: a program that prints...
Oct 26, 2012 at 9:22pm
[no replies]
array challenge
Array Sum Challenge In this challenge, given an array of integers, the goal is to efficiently find the subarray that has the greatest value when all of its e...
Oct 26, 2012 at 9:16pm
[no replies]
Help with Triangles please
Hi I am new to C++. There are two problems I am having an issue solving. The first one is : Design a date structure to store the triangle of numbers. Ea...
Oct 26, 2012 at 9:14pm
[no replies]
guess
The following program will act as a guessing game in which the user has eight tries to guess a randomly generated number. The program will tell the user each ti...
Oct 26, 2012 at 9:13pm
[no replies]
HOW DO I START GAME PROGRAMMING
Hi everyone, I need some advise. I've been studying C++ for almost 18 months now and I've just completed my Data Structures course. I'm interested in learning g...
Oct 26, 2012 at 9:13pm
[12 replies] Last: SFML is extremely easy to learn and use. written in C++ in an OO manne... (by majidkamali1370)
question
Which of the following statement is correct? A. C++ enables to define functions that take constants as an argument. B. We cannot change the argument of the ...
Oct 26, 2012 at 9:10pm
[1 reply] : C is correct (by majidkamali1370)
problem
#include<iostream.h> long FactFinder(long = 5); int main() i keep getting problem. i dont know what is the problem { for(int i = 0, i<= 0, i++){ ...
Oct 26, 2012 at 9:09pm
[no replies]
C++ hard topic for me
I am new to this C++ language. This is my first time here. i just need help for the problem pasted below. i will gladly accept any suggestions or code example p...
Oct 26, 2012 at 8:02pm
[6 replies] Last: OP for ref: I am new to this C++ language. This is my first time he... (by Moschops)
what does this code do
what does this code do and i want to know why using the % sysmbol is appropritate here. thank you for helping int fib = {0,1,1}; for(int i=2; i<=n; i++) { ...
Oct 26, 2012 at 8:01pm
[2 replies] Last: OP for ref: what does this code do and i want to know why using the ... (by Moschops)
by Kart
Standard
Hi I have seen the advanced advisers on the forum quoting references to sections in a Standard when assisting members. Is this Standard being refereed to o...
Oct 26, 2012 at 7:48pm
[2 replies] Last: Thanks Moschops-very much appreciated... I guess another bedtime story... (by Kart)
Searching a string of numbers
I have a vector that holds a bunch of numbers for objects. But say you got the numbers "2, 3, 4, 6", and say when I used the function to create them, I created ...
Oct 26, 2012 at 7:45pm
[13 replies] Last: Alright, cheers. (by Callum5042)
Input a file and output some data
Hello everyone, I got an assignment that i have to use the code to input a file (which can be .txt or anything, and there are some data in .txt).I have to enter...
Oct 26, 2012 at 7:41pm
[1 reply] : if (myReadFile.is_open()) { while(!myReadFile.eof(... (by SamuelAdams)
How to declare Class name from another variable
I want to do something like this, void create_database(string A,string filename) { Database A; . . . Any idea how can i do something like this?...
Oct 26, 2012 at 7:13pm
[9 replies] Last: ok, i understand now, thank you. (by unkn00wn)
by BandK
How to update Array?
This is what i want...Picture is on link... Please help :( http://www.freeimagehosting.net/8puoq And this is my code.... #include <fstream> #include <...
Oct 26, 2012 at 5:46pm
[no replies]
October 2012 Pages: 1... 7891011... 50
  Archived months: [sep2012] [nov2012]

This is an archived page. To post a new message, go to the current page.
Registered users can post in this forum.