49,761 Topics

Member Avatar for
Member Avatar for wombomatt

I am currently working on a banking system that has 3 classes. customer, savingsAccount and transaction. I have created the 3 classes but am having problems with the saveAcnt object in the customer class. I need to link it with the savingsAccount class. Any help would be appreciated. Also I …

Member Avatar for dkalita
0
257
Member Avatar for lalala423

Write a program that finds the greatest sum of three adjacent numbers in any direction (up, down, left, right, or diagonally) in a 20x20 grid of numbers. All input data must be obtained from the stdin prompt. You can feed in the data from a file by using input redirection. …

Member Avatar for pseudorandom21
0
159
Member Avatar for triumphost

The code below is from my form.. I declared a string GLOBALLY.. Then upon FormLoad, It inserts values for the string... When I do button click, the string is blank.. Why is it blank? Shouldnt the Values from FormLoad Event be in it? : [CODE] public ref class Form1 : …

Member Avatar for jonsca
0
118
Member Avatar for jfunchio

I'm trying to implement an observer pattern that keeps track of uppercase letters in a line of text the user enters. Whenever there is an uppercase letter the observers are notified. It compiles fine and when I run it and enter a line of text with no uppercase letters it's …

Member Avatar for template<>
0
139
Member Avatar for jowana

Hello, I am wotking on a project for 'segmentation' using ITK in C++ in Visual studio 2008 now, I want to copy an example code from Examples in ITK and use it in my program. To be specific , I am using "ShapeDetectionLevelSetFilter" If I try to build my program …

Member Avatar for Ancient Dragon
0
178
Member Avatar for triumphost

Can someone explain why it wont find the window?? I did everything right, Im pretty sure of it :S Yet it just wont find it. EDIT: Admin delete.. I think I just figured it out.. [CODE] private: System::Void Form1_Load(System::Object^ sender, System::EventArgs^ e) { Form1::Visible = false; Query ^ F = …

0
85
Member Avatar for subwired

Hi, Just a quick question, I need to add extra functionality to some code but I have found syntax I am unfamiliar with. I'm pretty much a noob to c++ so it probably quite simple but I have had enormous problems trying to define a search term for google and …

Member Avatar for abhimanipal
0
118
Member Avatar for hawita

Please help its urgent i wrote this program but the output is not right. The program is not inversing the order of the words in the string. for example: input: i love school output: school love i . Please help thanks [CODE]#include<iostream.h> #include<string> using namespace std; main() { std::cout << …

Member Avatar for abhimanipal
0
198
Member Avatar for bigwhiteegg

I'm trying to auto-download any website's source code by entering its URL I did some search on Google and the forum only found this [URL="http://www.autoitscript.com/forum/topic/70853-inetgetsource-with-post-string/"]AU3[/URL] but its a AU3 file and I do not understand it at all does anyone has a suggestion for me? any website that I should …

Member Avatar for Stefano Mtangoo
0
148
Member Avatar for jfunchio

I'm trying to implement an observer pattern who's subject monitors for uppercase letters in a line of text entered by the user. I havn't had much problem until now i'm getting the error "error C2243: 'type cast' : conversion from 'UpperCaseMonitor *' to 'Observable *' exists, but is inaccessible". I …

Member Avatar for jfunchio
0
163
Member Avatar for oybek

Hi guys, I'm not good at programming so would you help me with this?! No fancy codes, just make it simple. Problem Statement For research purposes and to better help students, the admissions office of my college wants to compare how well female and male students perform in certain courses. …

Member Avatar for oybek
0
159
Member Avatar for Lokril

Having trouble with this assignment can anybody give my a hint as to where I should start? Write a program that prints letter grades based on a score (between 0 and 10) entered from the keyboard. The simplified scoring system will be: 9-10 A 8 B 7 B- 6 C+ …

Member Avatar for WaltP
0
2K
Member Avatar for sms5660

I am really confused about how to write functions before main(). My teacher didn't explain it well at all or the stipulations. I have a homework assignment due this weekend and I am so confused. Here is the prompt, below that is my program and what I think I should …

Member Avatar for sms5660
0
131
Member Avatar for 00musdan

Hey guys I am a noob when it comes to this stuff. I go to college for electrical engineering and me and my professor were discussing a cool senior project. There are regular vending machines in most buildings of the school that are connected to the schools network. The ethernet …

Member Avatar for davidchilders
0
184
Member Avatar for triumphost

K I just got this Idea that I want to implement into a program I downloaded. Yes the program is open source but I dont wanna compile it, I just want to sort of Inject?.. What I want to do is add a button to the program and have the …

Member Avatar for triumphost
0
125
Member Avatar for El3et

Im learning about postfix and prefix operators and how to overload them. I've created my class with overloaded pre and post fix operators how ever when used in the main program the results aren't what I expected. The program creates a simple shape from a class that has default constructor, …

Member Avatar for El3et
0
131
Member Avatar for jerbElijah

your kindness is highly appreciated....:-) this is it: ----The New telephone company has the following rate structure for long-distance calls 8:00 am (0800 hours) is discounted 50% ----any call started or after 8:00 am () but before 6:00 pm (1800 hours) is charge full price. ----all calls are subject to …

Member Avatar for KumarUtkarsh
-3
297
Member Avatar for shauzi158

People. As i have my course of Object Oriented Programming, thus my Final project is to make a game in c++ using allegro. Please provide me basic knowledge because i have no idea of using allegro and game development. i would also be needing some good and easy game ideas …

0
56
Member Avatar for bleedsgreen33

This is my first time with link lists. I have gotten it to pull the first bit of information into the first node, and it prints out fine after that into the console window. When I try to add additional lists and link them, and then try to print them …

Member Avatar for drkybelk
0
84
Member Avatar for |Mike|

Hello! I'm trying to modify opensourced application but due to lack of knowledge, I'm stuck. Explantions are in the comments of the app :-) Thanks in adavance for your support! [CODE]void CBaseGame :: FixSlots( ) { struct Struct1{ list<string> UserList; list<CGameSlot> PlayerSlots; }; list<string>::iterator IT; list<CGameSlot>::iterator TI; for( vector<CGamePlayer *> …

Member Avatar for mike_2000_17
0
230
Member Avatar for comSysStudent

Hi all, I have a programming assignment to store sparse matrices using a list<list <myclass> >. I have pretty much everything nailed down but I'm going wrong at some point, the output is incorrect. Instead of giving me 4 lines with the column position and value of non zero values …

Member Avatar for comSysStudent
0
189
Member Avatar for gregarion

[CODE]#include <stdlib.h> #include <iostream> #include <cstring> #include <string> /* Include directly the different headers from cppconn/ and mysql_driver.h + mysql_util.h (and mysql_connection.h). This will reduce your build time! */ #include "mysql_connection.h" #include <cppconn/driver.h> #include <cppconn/exception.h> #include <cppconn/resultset.h> #include <cppconn/statement.h> using namespace std; int main(void) { sql::Driver *driver; sql::Connection *con; sql::Statement …

Member Avatar for mcriscolo
0
1K
Member Avatar for pseudorandom21

I've found that often in my code I have a need for primitive variables protected with synchronization objects such as a boost::mutex, and I was wondering if the boost library provides a template similar to this one I'm considering, based on the C# property methods get/set: [code] template<typename var_type> class …

Member Avatar for vijayan121
0
255
Member Avatar for Veneficvs

Hello everyone. I am having hard times in dealing with this problem which I've been given. It simply asks me to shift an array K positions without using additional memory. I cannot ask them what they mean by that. No memory, like... not even using a temporary variable for the …

Member Avatar for vijayan121
0
2K
Member Avatar for keeda

Hi, I am in process of creating a Money class, as per requirement I am suppose to represent each denomination by a class(eg: $5Class, $10Class etc.). I want to use inheritance in this scenario. I cannot think of the class design. I was able to create a class design for …

Member Avatar for Fbody
0
266
Member Avatar for Bedo

I need help in pulling this program apart, and reformatting it to use functions that I didn't know i needed to implement until right now. * float calculate_time (4 parameters) finds the amount of hours between two times given. It should return 0 if the amount is less than 0. …

Member Avatar for jonsca
0
113
Member Avatar for saya_afiq

one way to eveluate a prefix expression is to use queue. to eveluate the expression scan it repeatedly untill you know the final expression value, read it repeatedly untill you know the final expression value. in each scan replace an operator followed by two operands by the calculated value. for …

Member Avatar for rahman86
-2
78
Member Avatar for ztdep

Dear friends: I wrote the following c++ codes to create a series of filenames as "iteration number.dat". [CODE]#include <iostream> #include<string> #include<sstream> using namespace std; int main() { string outbuffer; ostringstream outs(outbuffer); for (int i=0;i<5;i++) { outs<<i<<".dat"; cout<<outs.str()<<endl; } cout<<outbuffer; return 0; } [/CODE] I tried to use the ostringstream to …

Member Avatar for jonsca
0
112
Member Avatar for Celtrix

Hey Just thought I might post some code I've Been refining its not really useful but it shows (sort of) how to print formatted text if you have any suggestions please I've almost got the kinks out weird numbers will cause it to output weird. But if you throw 9 …

Member Avatar for Celtrix
0
156
Member Avatar for ekin5683

What wrong with my coding? when i run..nothing appear.. The output should be: Perimeter of Rectangle 1: 22 Perimeter of Rectangle 2: 6 Perimeter of Rectangle 3: 18 Perimeter of Rectangle 4: 4 [CODE]#include<iostream> using namespace std; const int TOTAL= 4; void CalculatePerimeter(int perimeter[], int width[], int height[]); //const int …

Member Avatar for dkalita
0
83

The End.