49,757 Topics

Member Avatar for
Member Avatar for eagles39

I need help making this program setup in a way my professor wants it. I did the program and it works fine I have to add the percentage correct that I will finish after I try to set it up correctly. the files are attached below. biggest issue is understanding …

0
74
Member Avatar for bigwhiteegg

following is my main program Linklist is a class of circular Linked list so my question is since the parameter of function doesn't contain Linklist in it can I go ahead and call it "List" in any function, such as List.print(), anyway? [CODE]main() { linklist list; int choice, num; do …

Member Avatar for Taywin
0
156
Member Avatar for gmfreak1991

I'm creating a Wheel of Fortune program, and I have just started. Currently I'm just trying to take a word from a file and transfer it into an array, and with that create an array with the same size, but full of asterisks (*'s). My class is making me use …

Member Avatar for gmfreak1991
0
513
Member Avatar for lotrsimp12345

Having problems with executing jobs using fork. The code is supposed to create one job and execute one job and repeat this multiple times. We are only supposed to use usleep in the jobgeneration() function. We are having trouble sleeping and executing ctrl-c in the execute job function. [CODE] #include …

Member Avatar for lotrsimp12345
0
507
Member Avatar for andimiami

I think I am only making this worse and worse... I need to write a program that uses functions and a for loop to calculate a hat size, (`2.9*weight in pounds/height in inches`), jacket size (`height in inches*weight/288`), and waist size (weight in pounds divided by 4.9)... I know this …

Member Avatar for sfuo
0
174
Member Avatar for harshalpagare

i have a sign up programme in c++, like that of facebook . and i want a code to change password for a user, in that app which i have made please give me fully written code. i am in trouble it is my assignment of college.

Member Avatar for SgtMe
-2
90
Member Avatar for Akatosh

I want to know how to make a plugin framework in c++. I have searched for some topics and have found a few to get me started but I still don't understand the concept. I'm making an IDE and would like to add the functionality of plugins...I know you have …

Member Avatar for Stefano Mtangoo
0
216
Member Avatar for watery87

Hello guys im been tasked to do a series of complex functions. so far im able to complete addition, subtraction and multiplication, but currently stuck at division. Would appreciate any kind soul help on this [code] class Complex { public: Complex( double r, double i ) : re(r), im(i) {} …

Member Avatar for mrnutty
0
211
Member Avatar for geethasree

Hi All, this is my first query after joining the forum. I would like to know following points: 1. If I can create threads in constructor 2. If yes, can I use the same object / instance (which created this thread)in this thread to call other methods of the class …

Member Avatar for geethasree
0
2K
Member Avatar for georgy9002

hello: Is there a method for using and saving your work on a usb stick. I tend to use multiple PC's all using VS. Is there a way to use this method?

Member Avatar for daviddoria
0
65
Member Avatar for baconswife

Can someone help me on this? While considering the following function definition: [CODE]void defaultParam(int u, int v = 5, double z = 3.2) { int a; u = u + static_cast<int>(2 * v + z); a = u + v * z; cout << "a = " << a << …

Member Avatar for arkoenig
0
129
Member Avatar for Syrne

Hello! So for my assignment I had to declare an array of 25 student objects and input data into them including another array of 5 test scores. All that is done and works flawlessly(At least that's what I think), but the last portion of the assignment is for me to …

Member Avatar for Syrne
0
995
Member Avatar for simply_viks

how to connect multiple clients to a single server....??? i hv a server and a client connected to each othr. and sending and receving data. through tcp/ip proto. now i want to make connections with other clients also. plz help me..

Member Avatar for Ancient Dragon
0
148
Member Avatar for burcin erek

easy program... but x_1 and x_2 strings dont change after return from function I expect 50 and 70 but still keeps declaration value. [CODE]#include <cstdlib> #include <iostream> using namespace std; void absurd (string a, string b) { a="50"; b="70"; } int main(int argc, char *argv[]) { string x_1="burcin"; string x_2="erek"; …

Member Avatar for Fbody
0
112
Member Avatar for heidik

Hello everyone. Is it possible to read two lines of a file in one iteration based on some condition? The files has several blocks of data where each block contains two consecutive lines having ORDER ID in it. I want to store each of these IDs for each block of …

0
88
Member Avatar for M a H a

hi everyone = ) i wrote program using C++ it's for type a small letter then it will print it back in a capital letter using file processing i wrote the letters in txt file in the same c++ folder like this way a A b B c B and …

Member Avatar for Fbody
0
348
Member Avatar for mbouster

Dear all, I am new to this and I need ur help. I have the following problem description Write a C++ program that defines 3 arrays of integers a, b, c and 3 integers counts cnt_a, cnt_b , cnt_c. The program must then ask the user for the number of …

Member Avatar for mbouster
0
108
Member Avatar for BlackPhoenix

Hi everybody. As of now, my server will accept clients in a loop, and will pass those clients off into a new windows thread. Inside the thread, the server will be able to receive any data each client may send. When a client connects, the clientsConnected variable increments. So when …

Member Avatar for simply_viks
0
354
Member Avatar for bigwhiteegg

here is my question say I have a struct nodetype in the header file named linklist.h there contains a struct constructor in the nodetype named nodetype(int, nodetype*) how to I declare the code in the linklist.cpp? do I do the same for class constructor or something different?

Member Avatar for bigwhiteegg
0
77
Member Avatar for blackrandom

Okay, I have a header file I am trying to stub out to my_list.cpp but I keep getting these errors that I do not understand and have been working down to them but I got stuck. I figure I'm in deep trouble seeing as I can hardly stub these out, …

Member Avatar for blackrandom
-1
208
Member Avatar for sairakhalid

How can i make addition in my linked lists if the nodes are stroing two values: 1) int element 2) int colomnvalue i have to make the addition on the basis that the nodes having the same colomvalue, thier element should be added. This addition is to be made in …

Member Avatar for Taywin
0
162
Member Avatar for cbsinc

This compiles with no problem, but my calcCost function returns jibberish. I’ve tried many different combinations and I know it’s something simple. If I change my calcCost function to void and cout totalCost, it works fine, But I need the return value for another class (Order) that I need to …

Member Avatar for Taywin
0
114
Member Avatar for Shijo Jose

I am trying to create a program to log the medal tally of the cwg. However,I'm still getting wind of using binary files. It seems as if nothing is being read from or written into them. Below is my entire code. It would be of help if somone could direct …

Member Avatar for Taywin
0
199
Member Avatar for manofhouse

This is the Header file [CODE]#ifndef STUDENT_H #define STUDENT_H // class Student definition class Student { public: Student( char *nPtr ); ~Student(); void displayGrades() const; Student addGrade( int ); static int getNumStudents(); private: int *grades; char *name; int numGrades; int idNum; static int numStudents; }; // end class Student #endif …

Member Avatar for thelamb
0
377
Member Avatar for marvolo1300

Hi, Im trying code something which will launch an executable file. I have tried system("example") but the only problem is that the file which has been launched has to be closed before the rest of the code is executed. Does anyone have an alternative to this method?

Member Avatar for Stefano Mtangoo
0
208
Member Avatar for Purrenhage

2 week in programming I am learning to program in C++. I started off with 26 error, and now I am down to 1. I just dont understand what it is asking for in the errors. Can somebody help me out? I have tried to look on the internet but …

Member Avatar for manojwali
0
151
Member Avatar for qvyhnl

I had created a Person class with 2 fields ages and name, its member functions are [CODE] Person::Person(string n, int a){ name = n; age = a;} string Person::get_name() const{ return name;} void Person::increment_age(){ age += 1;} void Person::print() const{ cout << name << endl; cout << age << endl;}[/CODE] …

Member Avatar for qvyhnl
0
145
Member Avatar for SgtMe

Hi all. There have been several threads where people are asking, [B]"is there any way we can develop iPhone Apps on Windows, or without using Objective-C?" [/B]The main reason people ask this is because [I]they either cannot afford a Mac, or cannot afford all the additional costs one has to …

0
184
Member Avatar for amoon wasfi

Here is the question: Write a program that outputs the following Pascal triangle using two nested for loops. 1 1 1 1 2 1 1 3 3 1 1 4 6 4 1 1 5 10 10 5 1 1 6 15 20 15 6 1 1 7 21 35 …

Member Avatar for Dakurels
0
148
Member Avatar for dspjm

Suppose I have these two functions: [CODE]template<class T> bool largerthan(T a, T b) { if(a>b) return true; return false; } template<class T> int reduce(T ar[], int n) { list<T> buffer; buffer.insert(buffer.begin(), ar, ar+n); [COLOR="Red"]buffer.sort(largerthan);[/COLOR] buffer.unique(); copy(buffer.begin(),buffer.end(), ar); return buffer.size(); } [/CODE] I have two kinds of arrays for reduce(): string …

Member Avatar for vijayan121
0
105

The End.