49,761 Topics

Member Avatar for
Member Avatar for sjcomp

Hello, This is not a c++ question per se, but I do not see a better forum to ask it. I have a binary executable (compiled with Visual Studio C++ 2005) and the source code for this file. I need to change a constant, but for various reason I do …

Member Avatar for William Hemsworth
0
753
Member Avatar for Mr Bin

#include <stack> #include <queue> #include <iostream> #include <fstream> using namespace std; char num[10] = {'0', '1', '2', '3', '4', '5', '6', '7', '8', '9'}; char ope[4] = {'+', '-', '*', '/'}; bool isope(char); bool isnum(char); int prio(char); queue<char> ReversePolish(); void write(queue<char> ch); void main() { queue<char> q; q = ReversePolish(); …

Member Avatar for VernonDozier
-1
97
Member Avatar for programmingnova

This next practice problem has me implementing functions into code I completed before calculating data about students. I'm getting an error message, and am looking for where my problem(s) are. Objectives of this problem: -Collect data from user: major, last name, credits completed, gpa, tuition paid. -Call a function to …

Member Avatar for dkalita
0
164
Member Avatar for lotrsimp12345

Don't think you can pass any parameter unless you create a point in your main. [CODE] template<class T> void my_list<T>::show_sllist(my_node<T>* p) { if(p!=0) { cout<<p->data; show_sllist(p->next); } } [/CODE] Would i have to create a pointer of type my_node in main to show the list. [CODE] #include <iostream> using namespace …

Member Avatar for dkalita
0
101
Member Avatar for nicholasamh

I am using C++. I use mkdir("C:/test") to create a directory to store my files. I want to hidden the folder that i created. Don't want to let anyone know about this directory/folder at all. Can someone help me out? Thanks alot.

Member Avatar for nicholasamh
0
86
Member Avatar for zackie

Hi guys, im new in C++ programming and hope anyone could guide me to understand C++ and be able to code my assignment out :) what the program does: 1. user inputs text file name, 2. user inputs key word 3. program goes about replacing character/strings in the text file …

Member Avatar for iamthwee
0
107
Member Avatar for JungWoo

I got stuck in this program and dont know how to start to phase 2, i finish phase 1 quite good bt i dont understand connection phase 1 and phase 2. so i hope some one can help me pls, thank you very much..... phase 2:Expand Phase 1 to translate …

Member Avatar for iamthwee
0
99
Member Avatar for UmH

hi i'm new in program i want to write code in c .. and i'll convert it to c++ but i've problem this is the code [CODE] #include<stdio.h> #include<conio.h> typedef struct std { int id; char name [10]; char status; }STD; void main() { STD m; printf("Enter id : "); …

Member Avatar for UmH
0
140
Member Avatar for psycoadeq88

we try to develop an interactive program for student to learn c programming.this program requires the following details. (1)-user information such as name and metric number (2)-exercises from functions,arrays,string,structure create minimum 10 objective question for (2). your system should show answer chosen by the user and finally the result and …

Member Avatar for K0ns3rv
0
97
Member Avatar for Nickair

Hi i am looking for a good C compiler for windows vista. I found Visual Studio C++ 2008 express edition, will this work if im writing in c?

Member Avatar for Nickair
0
101
Member Avatar for lotrsimp12345

problem is that it prints out backwards, can't figure out a way to flip it. prolbem is with numbers[siz-1] which begins at last index not first. [CODE] template<class T> T my_vector<T>::show_vector(unsigned int siz) { if(siz==1) { cout<<"enter size of array is 1\n"; return numbers[0]; } else { cout<<"enter this statement"<<endl; …

Member Avatar for lotrsimp12345
0
87
Member Avatar for gauri_phatak_87

hello everyone, I am trying to read the same file twice,but after the first reading it is not taking the value again. what i need to do is read the file once and count the number of lines in the file, then read it again and do further computations...... but …

Member Avatar for kvprajapati
0
176
Member Avatar for elio888

Hi, I have found this code that helps me convert the bearing and distance in to latitude and longitude. Lat/lon given radial and distance A point {lat,lon} is a distance d out on the tc radial from point 1 if: [CODE] lat=asin(sin(lat1)*cos(d)+cos(lat1)*sin(d)*cos(tc)) IF (cos(lat)=0) lon=lon1 // endpoint a pole ELSE …

Member Avatar for kvprajapati
0
105
Member Avatar for jjplaw

I have a protocol package that includes a list of .lib and its .h files that i wish to convert to dll to be used in a C++ environment. The .lib and .h files were developed in C. How do i go about it? I'm using VS 2005. Please advise.

Member Avatar for kvprajapati
0
123
Member Avatar for gretty

Hello I am studying for my exam & I came across this question that is stumping me. [CODE=cplusplus] class X { public: X(); private: int x1, x2; }; class Y : public X { public : Y(); private: int y3; } // the class Y does not end in an …

Member Avatar for kvprajapati
0
4K
Member Avatar for complexcodes

Hello, I am writing a class that can handle large number of digits. I am trying to overload >> operator so that it can store the user input value and if user entered nondigit then it should print an error message and display the default value of 1 ; overload …

Member Avatar for dkalita
0
283
Member Avatar for ehsantl

Hello folks I'm trying to do my assignment and I'm really stuck in! I have to classes..Customer and Pensioner (Customer = Super class and Pensioner = Subclass) The Pensioner has a PensionNo extra than Customer class. I have to make a array of Customer class (for 10) and put Customer …

Member Avatar for rbv
3
298
Member Avatar for wyett

So, I created a program that allows a user to create student, delete student, display all students, search students, and quit. They are labeled 1 - 5, respectively. However, if a user were to enter 1, create the student, be taken back to the main menu and typed in x. …

Member Avatar for wyett
0
187
Member Avatar for Web_Sailor

Hi, I am used to array of hashes in perl. So I was trying to do something like that in c++. Suppose I have created an array and now I want to store multimap in it. How can I do that ? I need to get some clues about this. …

Member Avatar for Web_Sailor
0
167
Member Avatar for IndyColts

Ok, I wanted to learn C++, so I went and found a tutorial. I started reading it, but now I have so many questions! FYI, I have little to no prior programming experience, so please don't laugh at me. 1) What is a compiler, how do I use it, where …

Member Avatar for IndyColts
0
125
Member Avatar for scantraXx-

Hey guys. I'm having trouble getting the largest/smallest value of an element in a set I created from my class. It has to return the largest/smallest element of specific elements that are set to true in my <bool> vector. Example: [code] int set::getLargest() const { if ( !setlist.empty() ) { …

0
75
Member Avatar for no_talents

I have a C program using winsock that connect to internet. however, now I am in Http Proxy environment that need to pass through the proxy before I can connect to internet. my program now is not support this. so Http/1.0 bad request is results. How I can support the …

0
96
Member Avatar for Carrots

Hi, I have been building objects on the stack using the following constructor: [CODE=c++] classname node(arg1, arg2); [/CODE] Which worked fine. But have now learned it is the heap I need to use. So I need to use the [B]new[/B] command I believe, but my syntax is wrong: [CODE=c++] classname …

Member Avatar for Carrots
0
133
Member Avatar for exualS

I'm trying to show a dialog when I press a button, I have made the dialog but I do not know how to access it from the main form code. For example: You can do: this->label1->text = L"Test."; But is there like a form1->label1->text = L"test"; like in basic?

Member Avatar for exualS
0
58
Member Avatar for Ponomous

So i want my program to loop while the user continues to say yes and i figured that my code below would work but for some reason it says that y is an undeclared identifier. [CODE]# include <iostream> # include <fstream> # include <cstdlib> # include <string> # include <cmath> …

Member Avatar for NathanOliver
0
110
Member Avatar for dqddani

Hello. This problem occured in a program that used dynamic memory, and the arrays were deleted and reallocated several times with varying length. It seemed to me that after deleting the arrays, the pointer is still pointing to some data with the same length. (And of course i didn't want …

Member Avatar for jbennet
0
513
Member Avatar for Ponomous

So I am trying to write a program that will give creditcard balance information and it is aparent when I compile that there is some sort of error ( error c2784 ). I think that I might not be including something that I need but I am not sure what …

Member Avatar for Ponomous
0
176
Member Avatar for kayot1k

Hi there, i need to know how to access my elements in a set of integers. i have private data for the following: private: vector <bool> setlist; // indicates set elements as true int cardinality; // number of items in set im creating a function that 'dumps' the elements of …

Member Avatar for kayot1k
0
81
Member Avatar for NICEGUY123

I tried my code below, and i am getting a output of 0. I added lines like cout << p; and cout << alpha to see if the values are getting stored into the variables. My output looks like this -18811398930we are in the loop0 Can anyone help me?? i …

Member Avatar for NICEGUY123
0
230
Member Avatar for Kgunner

Hi, I'm a new member to this website but have always checked it for help when needed and the people here seemed helpful. Anyways, for my data structures class I need to encode and decode data using a huffman tree. What I have so far is a working Huffman tree …

0
42

The End.