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

Compile problem
 
My Specs * WinXP on x86 * CodeBlocks 10.05 - mingw32-g++.exe and related (default) * wxPack for wxWidgets 2.8.12 * My Projects in 7Z: https://docs.google.co...
[7 replies] Last: Never mind, started including the cpp files too, still getting errors ... (by awsdert)
New to Functions
 
Below is my code. I have made this program and now am trying to use functions in it and I CAN'T use global variables. Can I get some pointers on what to do? Am ...
[no replies]
program messes up at one part
 
// Includes #include "stdafx.h" #include <iostream> #include <string> using namespace std; // Main Function int main() { string name , address , c...
[2 replies] Last: ok thank you (by Reaper1)
difference between const <type>& and const <type>
 
I came across the following declaration of vector, typedef std::vector<const xyz&> xyzTypeVector_t; where xyz is a union of structs Can someo...
[3 replies] Last: Thank you for the responses! ...is purely implementation-defined bec... (by DeepBlack)
Why static member variables must be explicitly initialized
 
Lets say I have a program as follows: #include <iostream> using namespace std; class X { public: static int var; int othervar; }...
[2 replies] Last: Hmm.. well according to ideone, both var and othervar are getting valu... (by Flurite)
AVG potential hack
 
Okay ... I have just obtained the visual studio 10 IDE express edition after continuous urges to shift from the archaic VS6. I have always been reluctant about ...
[10 replies] Last: You can find the Exclusions part of AVG in the Settings. You can then ... (by kreationTG)
C++ coding problem
 
Hi Everyone, My name is Hitesh Khurana, let me get straight to the point. I am working on homework for my programming class;however, I keep running into a pro...
[8 replies] Last: Update: Finally Completed the Program. Thanks to everyone that helped... (by HiteshKhurana)
SFML Still Wont install
 
So, I tried to install sdl and ended up installing sfml. The program works, but this code works: #include "stdafx.h" #include "SFML/Graphics.hpp" #include "SFM...
[4 replies] Last: Thanks So much! Im Guessing that changed between 1.6 to 2.0? (by Pickle Gunner)
std::vector Question
 
So I'm decompiling an function using global vector as some structure type. Here Is the source I get: struct SYS_SEARCH_PATH { char m_Driver ; } ; //size of 2...
[3 replies] Last: Thanks you very much. That was what I wanted to know. But can you tell... (by sasho648)
SFML tile slopes
 
I think the problem is nothing difficult i just cant seem to find it. This video illustrates the problem: http://s276.photobucket.com/albums/kk15/stkguy/?action...
[no replies]
Question on Functions with a For Statement
 
I have this code below and am new to functions. So if I were to do something like this: double myFunction(double randomizer, double selection); { //what d...
[2 replies] Last: oh duh. thanks! (by skittlesaddictx50v)
Help Please: I keep getting errors for this program and i dont qutie understand why. Help would be much appreciated :)
 
// Converting Ft and In: This program will convert user input from feet and inches to // meters and centimeters. #include "stdafx.h" #include <iostream> using ...
[9 replies] Last: Thanks for the help you guys :) I think i got it now~ (by xXxFarriexXx)
AVL tree
 
I was trying to write code to implement AVL tree, but I was getting a segmentation fault when I try to insert more than one element, I changed some functions bu...
[16 replies] Last: It's gonna be difficult for anyone to wade through that code. If you ... (by cire)
by MAQAH
Recursive Functions
 
Need a recursive function to print the alphabet in the reverse order (z-a) ? void print(char p) { if (p=='z') return ; print(p-1); cout<<p; re...
[18 replies] Last: Or even with templates... template< char A = 'a', char B = 'z' > vo... (by closed account o1vk4iN6)
crash this-->vector
 
Hi! I have this code that gives me a crash error when I put an object in a vector: Mesh.hpp class Mesh : public object { public: Mesh(); //inicial...
[3 replies] Last: Sorry, I found the error. I forget the dynamic allocation in other par... (by ShotoReapre)
OpenGL place many quads problem
 
Hey everyone, I am trying to write a script that will randomly generate squares all over the map however I can even get it to generate squares all over the map ...
[2 replies] Last: Hey I managed to fix the problem by reseting the x and y values before... (by mikeecb)
Editing Data in Structure Array
 
Hello! I am working on a program for my class, and the problem requests that the user be able to change data in a structure array: Write a program that kee...
[7 replies] Last: Glad I could help :) (by rollie)
random password generator from array
 
Hi guys, I am trying to write a program that will ask for users name, birthdate and pet and from those info I need to use a random number generator to select 6 ...
[1 reply] : What exactly are you struggling with? A few initial observations. Fi... (by MrHutch)
stdin unable to read data posted from html form
 
Hey frnds, I have written a html code which is sending data to a c program. But stdin is unable to read that data in c program. It seems stdin doesnot have a...
[1 reply] : Data was not getting posted properly on from html.....noe issue resolv... (by aditi88)
by Brody
vector size limit
 
I am getting a St9bad_alloc error when trying to allocate a std::vector<uint8_t> of size: std::vector<uint8_t> myVector(96*3*320*240*100); I calcula...
[3 replies] Last: The question I have to ask is why in the world do you need such a la... (by Brody)
October 2012 Pages: 1... 3839404142... 50
  Archived months: [sep2012] [nov2012]

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