49,761 Topics
| |
Hey guys, im about to write an application which has a visual GUI doing representation of a system (lots of pretty colours and flashing objects etc), which represent what is happening with packets and external devices being inserted into the system. I need to use one of the Win32 APIs, … | |
i need help with this very simple question.... the [I]default[/I] in this program will just display the [I]wrong input[/I] if the input entered by user is different with the data type of the variable which is [I]char[/I].. but not if the user entered the the word which is the character … | |
While I was browsing through the forum threads long ago, i saw a thread about one assignment given toits poster. Since i am learning myself(1 month left to enter university), I decided to try writing d program . Please, you are free to correct me if I am wrong anywhere... … | |
Hey How do you go about debugging? like tips and tricks? I have been looking at my code (below) for like an hour and cant figure out what i have done wrong..... [CODE] #include <fstream> // Header File for File Reading #include <iostream> // Header File for General I/O-put #include … | |
How can I call a value that was created in 1 function into another function so that it can be used as a variable? (i.e how do I implement the values that I found in my distance function, and use them in my radius function...) [code] #include <iostream> #include <cmath> … | |
Hello everyone. Im sure this is a simple winsock question but maybe im wrong... I searched everywhere and keep hitting dead ends. Im just learning how to use winsock and still have yet to find a good tutorial. But i found a class which i will start with. Only problem … | |
So my program is coming along, but now I am writing in the range checking to ensure that the inputs are actually what they should be. My code works fine for time, except for the fact that white space gets ignored. I need to ensure that a user cannot input … | |
here is the overloaded function i have. I have to enter a float, for example, .123 or 0.123. if there is many zeros in front, then it will skip them over, and test for a decimal, then count the numbers in the end. and then print them out. [CODE]MyFloat& MyFloat::operator= … | |
Hi all, this is just curious question on C++ and winapi. I have heard that win32api is written in C and at the same time I have heard people saying that "light weight" applications can be written using API. This boggles my mind on how C++ works with C-based API. … | |
Help!!! I'm trying to eliminate the highest and lowest number out of 5 inputs then get the average of the remaining 3 inputs... In some instances, it gives me incorrect average.. (We are not suppose to use arrays yet) Here's my code: #include <iostream> using namespace std; void getData(double& input1, … | |
Hey, I've created this class, it compiles OK but when I go to use the class it fails. It comes up with a pop-up saying something like 'Unexpected Error' 'Class' [code] class Person { public: Person(); Person(char theName[], float thePay, int theHours, bool Isworker); char* getName(); float getPay(); int getDepartment(); … | |
Hello HELP :( Ok I have an assignment due in 5 days. I have done [B]everything[/B] except for one function. This function finds the smallests factors of a positive int & it multiplicities, Have I lost you yet, dont worry because I've been lost for a week now with this … | |
I have a task to do about the std::string datatype. To do the task I need to Use KDevelop and be able to find the size of the buffer being used when performing operations upon strings, but never having used KDevelop before, I'm at a complete loss. Could anyone be … | |
I am supposed to create a program like this, with separate clock.cpp, clock.h, and main.cpp files. The program is supposed to do these tasks: I have started the clock.cpp and dont quite know where to go for some of the tasks, and I don't quite know how to use the … | |
| Hello, I've checked google now intermidintly for two days, and I could not find a solution for my problem, so I decided I would post my own thread on here. The program I'm designing is supposed to ask the user for a file name, open that file, then take the … |
how do i display something like this using [I]for loop[/I]? 0 2 4 6 8 10 12 14 18 24 26 28 30 32 thank you for helping... | |
Hi guys, anyone familiar with the Markov Chain Algorithm? I've got an assignment to take the code from a C++ implementation and remove any stl features like deques and maps, but continue to use strings as my main object type. I've based my changes around a C version of the … | |
my program reads om tje number of liters of gasoline per 2 cars and the number of miles traveled by a car and then its supose to output the number of miles per gallon the car delivered. I used .264179 as my conversion of liters to gallons. Everything seems fine … | |
Hey so my code below works. It finds the roots for values that are in the quadratic equation from a file. What i want to do is write a function that will count the number of positive roots. What would be the easiest way to do this? I was thinking … | |
I have to print a triangle in C++ where the length is double the height and base of the triangle it is to be isosceles this is my Isosceles code. how do I change the length base and width so that the length is double. We are only allowed to … | |
I am trying to figure out why my function isn't working when I compile the program....can anyone suggest anything? [code] #include <iostream> #include <cmath> using namespace std; double distance(); void main() { double center1, center2, point1, point2; cout << "Please Enter X-Value of Center: "; cin >> center1; cout << … | |
[CODE] #endif class BankAccount { public: double enterAccountData(); double computeInterest(); void displayAccount(); private: int accountNumber; double accountBalance; static const double RATE; } #include "stdafx.h" #include <stdlib.h> #include <conio.h> #include <stdio.h> #include <dos.h> #include <ctype.h> #include<iostream>// holds the cin and cout commands #include<conio.h>// holds the getche() instruction using namespace std; //#include … | |
Hi guys, wanting to write my own system which (for Windows XP) will monitor packets entering ports and scan them against known virus signatures. Also wanting to constantly check the registry and certain file directories (such as Windows folder) for changes to files which may suggest an attack- then an … | |
Hi guys, I am just wondering how to implement a dialog I have made in Microsoft C++ 6.0 So I created a C++ project, then added a .rc script file. Then I added a new item to it (dialog control, called IDD_MENU) Now, I am wondering how would I use … | |
Hey guys, I'm having a bit of trouble with an assignment that has been racking my brain. I'm taking a number from the user, using a function to print its reverse order, checking to see if it is a palindrome in the main program and also removing any leading zero's … | |
i need help with removing "s" and "tion" properly if i want to input "composition" it should leave me with "composi" but it leaves me with "compo" and if i were to enter a word that starts with an s and doesnt end with an s the word would not … | |
Hello I have given a program in which i have to declare structure to store account ID, amount, user name and address. It inputs the number of account holders from the user and creat a dynamic array of structures to store the records of accounts. The program should declare two … | |
Right I must first say, this is not homework, if it was, I might have a clue what I am doing. I am currently doing some research and as part of the understanding of the data we have produced I am trying to convolute it. For this I want a … | |
Hi, This is small c++ guess game, I almost finished it, but when i tried compile it gave me an error: "Cannot open include file: 'stdlib': No such file or directory" is this file part of c++ standard library..? why compiler can't find it? here is my .cpp source: | |
For the final part of our project, we're supposed to: Add the following constant (the file name must match exactly): const string MASTER_FILE_NAME = "master.txt"; 2. Create the file master.txt and add it to your project. The master file must contain account records (one record per line). Each account record … |
The End.