49,761 Topics

Member Avatar for
Member Avatar for g_riding

I am learning C++ and having a problem with adding numbers in a [10][10] array. It reads the data from a file. I have the array set up and I have to add the numbers diagonally left and right. I have to add prj6[0][0] then prj6[1][1] then[2][2] and so forth. …

Member Avatar for g_riding
0
443
Member Avatar for Ragster

Hi, this is my first time posting here so I'm sorry if I post something wrong. I have an assignment for my class and I think I have done everything right, well except for this one error that's been killing me. I get this error for each function call when …

Member Avatar for Ragster
0
703
Member Avatar for louiscos77

Hi guys, I'm planning to make a car game & for that I'll use Microsoft Visual C++ 2010 for programming, directX 10 for the graphics, & Nvidia PhysX engine for the physics. The problem is that I can't find any tutorial of directX and Nvidia PhysX, I only find of …

Member Avatar for louiscos77
0
558
Member Avatar for ace8957

Hi all, So I'm currently teaching myself about hash tables. I'm doing a programming challenge where I create a hash table that stores instances of a class Person, with data members for name, phone number, and GPA. The table uses separate chaining to take care of collisions. The node I'm …

Member Avatar for ace8957
0
264
Member Avatar for theashman88

I have to create a program that requires the user to enter the zip code. The zip code must be 5 digits. I know how to do that using if statement and string.length(). What I don't know how to do is how to make sure the program only inputs and …

Member Avatar for dnambembe
0
107
Member Avatar for qvyhnl

Can someone show me how to write a recursive function that count how many time the number 7 occur in an integer. Thanks

Member Avatar for mrnutty
0
98
Member Avatar for jsav

A program I'm trying to compile is simply not working right. I have everything defined the way it should with all the right #include statements there. However, anytime I try to compile with g++, it tells me the functions are undefined. Really, I should not be getting this error. I …

Member Avatar for jsav
0
279
Member Avatar for NU8

I am trying to create a queue class and then allow the user to input integers at the back of the queue and take them from the front. This is what I have so far, it runs but will not output the size of the queue correctly. Any help would …

Member Avatar for NU8
0
120
Member Avatar for jontes

Hello, I'm new here, so I hope I'll ask my question correctly. I have an assignment to create a "text-based cosmic adventure" and all went well until now. My project is separated into several header and implementation files. Problem arises only when I include certain file in another header file. …

Member Avatar for jontes
0
4K
Member Avatar for morewater14

Hi, I have a project to do for a C++ class that asks us to use a class termed "queue" to store some values (20/100/user defined) and allow the user to add/remove values. I'm sure it seems really basic, but I just can't get my code to display the class. …

Member Avatar for Fbody
0
180
Member Avatar for Smokehouse69

I inherited an ancient C program that was a Windows console application. The application connects to a data source and returns some values to the console. A very simple application. I had to make some changes and recompiled the code under Visual Studio 2008 C++. It compiled, linked and ran …

Member Avatar for Smokehouse69
0
198
Member Avatar for yardi

Hey am new to programming. Totally new. I am at the present moment kinda clueless. I want to be able to write software, attractive, efficient, useful software. My life is currently a mess. I have no skills, no profession, no job and I am twenty two, soon to be twenty …

Member Avatar for Akill10
0
80
Member Avatar for frogboy77

Hey there. I'm trying to figure out how to subtract one array of integers from another. I have figured out how to add 2 together going digit by digit and carrying over. I have no idea how to go about subtracting one from another. Basically i want to do simple …

Member Avatar for frogboy77
0
201
Member Avatar for DynamicMember

topic is writing a program for a milk factory. in factor there are 4.000 liters of milk and costs 1$ per liter.there are 4 markets that buy milk from this factory and sell it.so... the program must be such... you enter which company u r,then enter how much u want...and …

Member Avatar for Akill10
0
53
Member Avatar for SgtMe

I have made a python program which will create an OpenGL and render a teapot (GLUT standard teapot) with a shader that I specify. The shader is specified as follows: [LIST] [*]I have a file called "index.ini" which contains the file paths to a vertex shader and pixel shader file …

Member Avatar for SgtMe
0
479
Member Avatar for stemiros

Hi, I need some help with OpenGL and rotation. I have a 3D door surrounded by a holder. The holder needs to move with the door and rotate when it's not on the floor. After that the door must be able to open without affecting the holder. It's based on …

Member Avatar for daviddoria
0
380
Member Avatar for schoolboy2010

Hi I have a rather quick but very important question. I need to search a hash table for a value named element, whenever this value is found in the table, the search function should increase the counter for that element. My code is not working... any help is appreciated [code] …

Member Avatar for schoolboy2010
0
145
Member Avatar for muze

hello guys... i am trying to make a dll in vc++. Now I need to use some private function in the dll so that they might do some work for other functions that are called by original application. Here is what I am trying to do [CODE] namespace MyDll { …

0
65
Member Avatar for Philosophy

I am working on the last part of an encryption/decryption program and have to compare the original input file to the final output file character by character to ensure that they are identical. I have tried a few different ways to do this to no avail. When I tried this …

Member Avatar for Philosophy
0
490
Member Avatar for svatstika

Hello everybody! I'm trying to create a class calling INT, that is equivalent to the type int. I really don't know exactly what're inside class int. What I know is int is a type. I think what I need to do is create a class with operators like: +, -, …

Member Avatar for Ancient Dragon
0
92
Member Avatar for lordelf2004

Hi everyone! I have problems in using pointer with reference. So, I make simple program to clarify them. First of all, this is my code and its output. Please notice line (*) and (**): My code: [CODE] //////////////////////////////////////////////////////////////////////////////////////// void RefFunc(int*& a){ int q = 888; a = &q; //PROPLEM HERE …

Member Avatar for lordelf2004
0
116
Member Avatar for AMetnik

[B]Hej i am getting the error:[/B] [CODE]error C2440: 'initializing' : cannot convert from 'int *' to 'GarbagePointer<T>' 1> with 1> [ 1> T=int 1> ] 1> Constructor for class 'GarbagePointer<T>' is declared 'explicit' 1> with 1> [ 1> T=int 1> ][/CODE] -------------------------- But i really dont know how to either …

Member Avatar for daviddoria
0
2K
Member Avatar for Tiancailee

Hi i am trying to think of how the algorithm of how this question works but no matter how hard i tried, i cant think of it. Can anyone give me a hand?? Any help or tip would be greatly appreciated. Question: Given 3 classes, equilateral triangle, isosceles triangle and …

Member Avatar for Fbody
0
185
Member Avatar for roemhildtg

Hello all, I am enrolled in an intro to C++ class, and I need some help on our final program. Any suggestions are greatly appreciated, as I am quite new to this please don't criticize. Our program requirements require us to receive a command (I.E. delete) input as an array …

Member Avatar for daviddoria
0
208
Member Avatar for Lance5057

Ok so I have a game setup that allows the 8 to move around inside a small room. It works fine except that every keypress lags one "frame" behind. So whenever a key is pressed it does the last keypress that was given. How do I make it react immediately …

Member Avatar for daviddoria
0
115
Member Avatar for Jason Giggs

When we define an array, we have to declare its size before the program can be compiled. How can we specify it's size, say, by inputting a value from the user. I know a way with pointers; any other way?

Member Avatar for daviddoria
0
68
Member Avatar for exoticgurl

How to make a fibonacci pragram..can u help me.? high = 1 ; low = 0 ------------------------ high = 1 ; low = 1 high = 2 ; low = 1 high = 3 ; low = 2 high = 5 ; low = 3 high = 8 ; low …

Member Avatar for Jason Giggs
-2
86
Member Avatar for ProjectAce7

I am creating a program which includes converting numerical grades to letter grades but I'm stuck where I have to put a counter that counts number of letters. For example if 90-100=A and 90, 96, 87, 96 are entered, to count and display something like Number of As= 4 or …

Member Avatar for jonsca
0
2K
Member Avatar for Lance5057

How would you create a certain amount of objects based on user input? Like I have an enemy class and the player chooses how many enemies they want on the screen, how would I create those objects? Thanks

Member Avatar for caut_baia
0
83
Member Avatar for Alkaline8214

Ok well I got a final tomorrow and for the life of me I can not understand recursion. I have tried and tried and no hope lol. The professor gave us a study guide and I cant not figure out 2 problems. Just wondering if anyone can help me before …

Member Avatar for Alkaline8214
0
271

The End.