49,757 Topics

Member Avatar for
Member Avatar for haroldelam

[CODE]#include <iostream> #include <string> #include <iomanip> using namespace std; // //CLASS DECLARATION SECTION // class EmployeeClass { public: void ImplementCalculations(string EmployeeName, double hours, double wage); void DisplayEmployInformation(void); void Addsomethingup (EmployeeClass, EmployeeClass, EmployeeClass); string EmployeeName ; int hours ; float wage ; float basepay ; int overtime_hours ; float overtime_pay ; …

Member Avatar for haroldelam
0
114
Member Avatar for Jake1905

I am trying to figure out how to set a float for a project I am doing. Example I am trying to set a float for a score but I would like the input to be set where you can't input a number over a 100. This is the code …

Member Avatar for VernonDozier
0
124
Member Avatar for twitchybear

Everything works fine except when you roll a non-instant win or lose, you always win on your next roll #include <iostream> #include "Crapsfunctions.h" #include <conio.h> #include <ctype.h> using namespace std; void main() { double Money; double Bet; long Roll; long Roll2; long Point; long NumRolls; char Answer; //prototypes long throwdie(); …

Member Avatar for WaltP
0
163
Member Avatar for Suzie999

Can anyone tell me where to get started to get an md5 or sha1 checksum of a given file. I've searced around and all I can find are utilities, I also looked at wincrypt but It seems to me that it just does passwords and strings and suchlike. Any help …

Member Avatar for Suzie999
0
628
Member Avatar for taylord69

i have to write a function (dayNumber) that returns the day number in a year for a date that is provided as input data. i cant use const, struct, or loops, it has to be very basic stuff. i have something written but i can figure out how to get …

Member Avatar for taylord69
0
114
Member Avatar for techie1991

I was trying to code the assembly line sheduling problem using the dynamic programming approach. I have coded the program but i am facing problem with the 2-dimensional arrays I am using. For testing purpose, I wanted to initialize the array, but I was not able to get it. Moreover, …

Member Avatar for Fbody
0
212
Member Avatar for Ninoaoe

hi!!!! i'd like to ask if anyone knows how could i possibly use a string as a number...i mean: i've got something like cin>>word; but if that word is a number(like 1,2,3... etc) i have to use that number for going in that line. if user types ''hello'' its ok.but …

Member Avatar for Ninoaoe
0
129
Member Avatar for Diogo Martinho

I am facing a very simple problem that many of you will be able to solve, however I'm having a hard time trying to figure a method to program this. I am trying to create a dynamic array with the many prices of different clothing for a shop I'm creating. …

Member Avatar for Fbody
0
164
Member Avatar for heidik

Could anyone please show me a working example of how to find if a file exists but is empty or not? Thanks

Member Avatar for Ancient Dragon
0
342
Member Avatar for chiyuwang

In my programe I need to replace _open and _wopen by windows api function, I think the function OpenFile should be the one. Are their return values are same indeed, since _open/_wopen return int, while OpenFile return HFILE, and those enum type look confusing. Can anyone help with it? At …

Member Avatar for Ancient Dragon
0
84
Member Avatar for hag++

Hi All, I am writing an MFC Tic Tac Toe app and I am getting a strange error when debugging it. This module loads a bunch of BOOL variables to keep track of whether or not the tile next to it matches (i.e is the tile next to me also …

Member Avatar for hag++
0
358
Member Avatar for Chalson

After i key in 20 different value of float, what command should i use so that i can determine the largest and smallest value from these numbers ?

Member Avatar for PsychoLogic
0
199
Member Avatar for punchinello

Hi I'm new to MFC programming. What do I do if I want to make my window look better? Say, with a button that is not rectangular but oval? And maybe throw in some animation effects? Thank you very much!

Member Avatar for punchinello
0
78
Member Avatar for morgon

I have made a wery simple program but i still get a linker error I have one class Node.h #[CODE]ifndef Node_H #define Node_H #include <iostream> using namespace std; //class node has four fields: type, child1, child2 and parent. The type is -1 if it is a inner node, 0 if …

Member Avatar for gerard4143
0
107
Member Avatar for ImaginaryHero

I am at the beginnig of the softphone project for my university final project.. I will implement a softphone with using SIP protocol and C++ language on linux. I need some advice about tutorials, usefull API and whatever which will help me. Thanks..

Member Avatar for alwaysLearning0
0
2K
Member Avatar for Suzie999

Hi. Hoping someone could direct me to a starting point for project. No code, I havent started yet. Im looking for a start on finding the proccess exe name that calls a function in my dll file. Just looking for a place to start looking.

Member Avatar for Suzie999
0
166
Member Avatar for Scoppio

Hi, i'm doing a small program that communicates with my first SQL Server, but I'm having some troubles with the C++ (I'm usued to C only, and use it for developing microcontrolers firmwares). What Im trying to do here is it: Write the USER and PASSWORD in a form, then …

Member Avatar for Scoppio
0
203
Member Avatar for Hey11

hello i wanted to ask how to create a function that makes the insertion code search for an occurence that i will insert with a cin , instead of picking the first occurence for example the array is arr[]={1,2,3,5,3,1,3} there are 3 threes here , i want to get the …

Member Avatar for myk45
0
105
Member Avatar for tKc

I am required to make a code that makes a pyramid with number of input lines "n" to a text file. What i figured i would do i make the program so that it makes a pyramid on the screen and then write it to a text file. This is …

Member Avatar for Agni
0
166
Member Avatar for pharoah85

Im new to c++, Ive been plowing through books,web,etc. Many of the things im learning seems redundant but being new as I am I figure that it stems from lack of knowledge. Now finally my questions...Whats the significance of using pointers to reference variables when i could just flat out …

Member Avatar for pharoah85
0
184
Member Avatar for arun_l

We are getting these constraint errors wherver OSAF calls like m_NCS_SEL_OBJ_ZERO(&nSelObjSet) is called in our code. This is while cross compiling using tilera compiler - tile-g++. With g++ it always compiles fine. Any pointers would be helpful. Sample Code: 102 // initialise and set selection object set 103 m_NCS_SEL_OBJ_ZERO(&nSelObjSet); 104 …

Member Avatar for arun_l
0
148
Member Avatar for sahil1991

hi to all, i was looking for some objective type questions on c++ on the internet............ i got few but some with wrong answers and some with no answers at all....... i would love to hav some e-book on it or a larger question bank with answers........suggest me some links …

Member Avatar for Ancient Dragon
0
170
Member Avatar for nickx522

I need help on "for" statement .Im doing exponents. I did a while statement already in which i checked if base is in range. help please. [CODE] for(int count = 0; count <=Expo; count++) Total1 = (dont know what this should be?) cout << setw(45) << "Total : " << …

Member Avatar for WaltP
0
196
Member Avatar for allizzee

I don't know how to make the computer play against me. Before I write more, anybody online right now to help. thx

Member Avatar for WaltP
0
112
Member Avatar for Nathaniel10

OK. I thought I understood pointers and such but this exercise is revealing that I do not. The task is to read characters into an array created on free store memory (heap), then print them out using the reference and dereference operators. My code (below) compiles and runs but does …

Member Avatar for Nathaniel10
0
122
Member Avatar for GregPeters

Hi all. I have recently been learning C++ and have gained a moderate understanding of how things work. Texts files seem to confuse me though so i was wondering if someone could help me out. :) Basically I have a text file which looks something like: [CODE]** <Question> What is …

Member Avatar for csurfer
0
241
Member Avatar for slychronic

Gooday i have a question to make a program using the connect function and all i hve done is below. how do i complete the the first loop and the second loop...on what i should do next here is my code so far, explaination will be appreciated....[CODE] #include <iostream> using …

Member Avatar for mike_2000_17
0
160
Member Avatar for jalenamichelle

what is wrong with this? i keep getting an error that says error C2059: syntax error : 'if' && error C2059: syntax error : 'else' [code] int main (void); void menu(void); int getChoice(void); int *year, *day, *month, julianday; int dayspermonth[] = {31, 28, 31, 30, 31, 30, 31, 31, 30, …

Member Avatar for WaltP
0
95
Member Avatar for dwhite459

I am trying to write a program that allows the user to input positive integers between 0 and 1000 and then outputs the highest value and the lowest value. The user should enter -1 to signify the end of their input. I am supposed to use a loop to achieve …

Member Avatar for WaltP
0
6K
Member Avatar for sharifyboy7

For my program I am supposed to implement an encryption and decryption algorithm. I then have to print it out using my functions I have to read the input from a file, “plaintext.txt” The file will contain plaintext strings that are all lowercase, and be of the format: 3 hello …

Member Avatar for hag++
0
261

The End.