49,757 Topics

Member Avatar for
Member Avatar for darkzero89

I'm currently taking a introduction course to C++ and I've been able to do the first 3 assignments without much problems, but this new assignment is kicking my butt. The goal of this program was to make a simple text editing program. I simply open a saved text document and …

Member Avatar for darkzero89
0
268
Member Avatar for astropirate

Greetings all How can i create an executable in run-time? (win32). i need a simple wrapper for different console commands. this is because i must have executable there is no way around it. so what i have come up with is passing the command that i want executed as a …

Member Avatar for ganbree
0
129
Member Avatar for JohanG

Hi! I am trying to design and build a plugin-system to a project of mine. The basic design is to use DLL's for each plugin. Each plugin have a special function that loads all of its functions as macros to the main engine, which has been passed as a pointer …

Member Avatar for ganbree
0
121
Member Avatar for rtwister

on line 53 it says menu is undeclared. but if i bought menu first then mcdonalds is undeclared. does anyone know how i can sort this out? ty [CODE] #include <iostream> using namespace std; double money = 50.00; void Mcdonalds() { cout << "Welcome\n"; cout << "How can i help …

Member Avatar for Tom Gunn
0
74
Member Avatar for nanchuangyeyu

Hi, I know the return value of generic search algorithm "find()" is of iterator type. Now how can I output the return value as numeric type? For example: [CODE] short myArray[4] = {2,1,3,7}; vector<short>mVec(myArray,myArray+4); vector<short>::iterator found; found = find(mVec.begin(),mVec.end(),2); [/CODE] In this code the variable found will be assigned the …

Member Avatar for StuXYZ
0
211
Member Avatar for rmlopes

Hi everybody, I am having some problems with a multi-threaded application I am developing. I get segmentation faults in different places, always related to std::string, using g++4.3.2 on Ubuntu 8.10 server. Here is an example: [icode] #0 0xb7e18bb6 in memcpy () from /lib/tls/i686/cmov/libc.so.6 (gdb) up #1 0xa8eb1014 in ?? () …

Member Avatar for ganbree
0
163
Member Avatar for doublebond

Hi Guys, Need some help....... I want 2 read a huge file which contains binary data. Is it possible for me to make use of hash tables to read the same? if so, how can I do it. If the key value of the hash function is and integer we …

Member Avatar for Tom Gunn
0
122
Member Avatar for fifarunnerr

Hello everybody, I started c++ half a year ago, with the .cpp programs. Now i want to create a program with the Windows Application forms. But how can i multiply with textboxes? I want something like: textBox1->text = (textBox2->text * 3) But this code gives an error, i need something …

Member Avatar for Salem
0
46
Member Avatar for narendrachandu

3. Create a class by vector with an array of” int” type as its member data (The array created dynamically)find the last largest and avg value of the vector 4. Explain the sequence of steps to be followed in performing the following operations over a binary file catching of empty …

Member Avatar for ~s.o.s~
0
203
Member Avatar for kingben

[code=c++] #define MIN_PASS_LENGTH 6 #define MAX_PASS_LENGTH 12 #define NUMBER_OF_PASSWORDS 3 #include<iostream.h> #include<stdlib.h> #include<time.h> #include<conio.h> #include<fstream.h> #include<string.h> //int i; //letters //int j; //numerals char rand_small_letter() { int nHigh = 122; int nLow = 97; int small_letter = ((rand()%(nHigh - nLow + 1)) + nLow); //values from 97 to 122 return (char)(small_letter); …

Member Avatar for mvmalderen
0
857
Member Avatar for dumdumsareyum

I wrote this program back in high school 10 years ago and I found it today. I'm getting back into programming and I'd like to get it working again, some of the headers are deprecated which I tried to fix, and I was using borland c++ and now have Dev …

Member Avatar for Salem
0
143
Member Avatar for VBNick

Hello~! ...again.. I got some help from you guys a while ago with this same app because it wouldn't run on winxp. It runs fine now, but my brother is still telling me he cant get it to work right...so rather than go through all the trouble of trouble shooting(he …

Member Avatar for Salem
0
254
Member Avatar for narendrachandu

1. Create a class by name student with the necessary member data provide the facility. A. Create a list of stack B. search a student by reg.no 2. Create a class by name dates A. overload “<” operator to compare two dates B .overload “++” operator to compare date by …

Member Avatar for Salem
0
211
Member Avatar for nanchuangyeyu

Hi, I am now using VS2005 to write a console program. Since the [CODE]int main(int argc, char** argv) [/CODE] function is designed to accept parameters, how can I pass them to the program while debugging in step by step mode?thank u in advance.

Member Avatar for mvmalderen
0
89
Member Avatar for metzenes

I'm developing a recursive method for a class which will return a complicated data structure (a list of dictionaries which will contain lists of dictionaries as values). The data structure could be something like that: list<map <string,list<map <string,list< map<string,list<...> > > > How can I refer to this structure while …

Member Avatar for jencas
0
279
Member Avatar for csayantan
Member Avatar for umair125

i am doing bscs from GCU lahore PK.i have assigned a project name as MOVIE RENTAL STORE using OOP concepts plz help me to do my project i,ll b thankful to you, umair ahmad

Member Avatar for Ancient Dragon
-1
478
Member Avatar for ynaffit

i tried to create a program that would get the sum of the squares but i couldn't get the right output. Could u help me debug? and tell which part of my codes where wrong.PLEASE! :S [code=cplusplus] #include<iostream.h> #include<conio.h> #include<math.h> int x,num; int f(int); main () { clrscr(); cout<<"Enter a …

Member Avatar for nirav99
0
109
Member Avatar for Clawsy

Hello, I'm making an application in Visual C++ that hides/shows an application window from taskbar by clicking a button. First problem (googled it) is that I don't know how to retrieve the information about a window state (SW_HIDE,SW_SHOWNORMAL, etc.). Is it hidden, minimized, normal or maximized? I only know how …

Member Avatar for Clawsy
0
4K
Member Avatar for qkslvr1621

right now im working on a program that reads a series of numbers (doubles) from the user, then prints the mean and the range. also: • I do not know ahead of time how many numbers will be in the list. • When ctrl-z if pressed, stop asking for user …

Member Avatar for wildgoose
0
135
Member Avatar for lancevo3

Today is the first day I have attempted Operator Overloading and am running into a few errors so any assistance would be great! The first one I'm having issues with is here: const MyString& operator=(const char* rightOp) The assignment operator should also be overloaded to allow assignment of a C-style …

Member Avatar for wildgoose
0
244
Member Avatar for kramer4583

I have been working on this program for school, it does some things right but with a few things I am struggling. [QUOTE]For this assignment you will be writing a two person chip game. You will start out with a pile of 1000 chips. Each player will have the chance …

Member Avatar for kramer4583
0
185
Member Avatar for Humbaba

[code] int number; char letter; cout << "\nEnter a number\n"; cin >> number; cout << "\nEnter a letter\n"; cin >> letter; cout << "\nThanks!"; [/code] Let's say I had 5 of these questions lined up, it seems the user could just type something like "1 a 2 3 4" on …

Member Avatar for Dave Sinkula
0
84
Member Avatar for Ather14

I am trying generate even fibonacii numbers less than four million, but I keep getting negative numbers at some point and eventually it converges to a positive answer, which is obviously wrong. Can anyone please help me out? #include <conio.h> #include <stdio.h> void main (void) { clrscr(); int f1=1; int …

Member Avatar for NathanOliver
0
178
Member Avatar for mrnutty

How could one share a .exe that loads textures. I am using c++ and openGL. I want to share the .exe that I made using rapidshare.

Member Avatar for mvmalderen
0
80
Member Avatar for daviddoria

I'm trying to start writing tests for all of my functions as per Test Driven Development. My question is, say I construct a test for "rotate vector". It would be something like this: [code] int TestRotateVector(const Vector &V) { Vector Original(1.0, 2.0); Vector Rotated = Original.Rotate(10); //rotate 10 degrees if(Rotated …

Member Avatar for StuXYZ
0
182
Member Avatar for ivanhuk

I've created a class and create two new objects from that class. 3 variables are stored as private. I have mutator and access functions for these variables. When I try to write a value through these functions, they don't seem to change the variable in the class. What am I …

Member Avatar for Lerner
0
142
Member Avatar for shopnobhumi

What could be the possible explanation of this program output? I am trying to learn c++ so please help [code]#include <iostream> using namespace std; int main( ) {int b[3][2]; cout<<sizeof(b)<<endl; cout<<sizeof(b+0)<<endl; cout<<sizeof(*(b+0))<<endl; // the next line prints 0012FF68 cout<<"The address of b is: "<<b<<endl; cout<<"The address of b+1 is: "<<b+1<<endl; …

Member Avatar for Ancient Dragon
0
173
Member Avatar for walter clark

I have a Windows program (Visual C++ CLI Type) that displays video in a sub window. When something happen the user makes a note of the event by hitting a button. The problem is that the event involves a number of choices and finding the right button to click is …

Member Avatar for walter clark
0
71
Member Avatar for teddyg18

I have a program in which i open a a text file, access it's values and create and array with it. for example the text file may contain these values: 1 44 3 4 33 6 7 8 61 10 ; that's 10 integers what c++ tools could i use …

Member Avatar for teddyg18
0
6K

The End.