49,757 Topics

Member Avatar for
Member Avatar for daniel1977

Dear Friends: I am working on a prject and I am receiving these three errors: Warning 1 warning C4244: 'argument' : conversion from 'time_t' to 'unsigned int', possible loss of data F:\College Material\CS270\SourceCode\Exec11_14\Exec11_14\BST.cpp 18 1 Exec11_14 Error 2 error C2664: 'bSearchTreeType<elemType>::postorderInsert' : cannot convert parameter 2 from 'bSearchTreeType<elemType> **' to …

Member Avatar for UFOOOOOOOOOOO
0
153
Member Avatar for Stpdoug

Hey guys i am having trouble with creating a Parent class(gameobject) for two other child classes(player,location) both of the child classes can access data from the parent class, and work well independently but once i include the h file for the child classes together in main.cpp i get the compiler …

Member Avatar for UFOOOOOOOOOOO
0
354
Member Avatar for Henshens

includ<iostream> includ<conio> using namespace std; int x,z; char op; switch(op);{ cout<<"input two a rate"; cin>>x z; cout<<"category operator ( + , - , * , / , %)"; cin>>op; swich(op) case'+':cout<<"opertor +"<<x+z<< endl; break; case'-':cout<<"opertor -"<<x-z<<endl; break; case'*':cout<<"opertor *"<<x*z<< endl; break; case'/':cout<<"opertor /"<<x/z<<endl; break; case'%':cout<<"opertor %"<<x%z<<endl; break; default:cout<<"your are false"; …

Member Avatar for UFOOOOOOOOOOO
0
186
Member Avatar for princessophia

I am supposed to write a program that asks for the name of a pole vaulter and the dates and vault heights ( in meters) of the athlete’s three best vaults. It should then report in height order ( best first), the date on which each vault was made, and …

Member Avatar for UFOOOOOOOOOOO
0
281
Member Avatar for flony

hello friends, trying to understand a little work with txt, and in c + +, the file I can not open and goes straight to the end, what will my mistake the file is called nombres.txt and contains > carlos, alberto, raul, tomas, and the code is #include<iostream> #include<fstream> #include<string> …

Member Avatar for flony
0
200
Member Avatar for Brian1983

How would I go about modifying this code to accept characters instead of integers? #include <iostream> #include <cstdlib> using namespace std; struct node { int key; node *next;}; int main(int argc, char* argv[]){ if(argc >2) { int i, N = atoi(argv[1]), M = atoi(argv[2]); node *t, *x; t = new …

Member Avatar for Brian1983
0
184
Member Avatar for abhimanipal

Hi Guys, I am trying to teach myself templates and I keep getting lost in all these compilation errors. Here is the latest // This is the interface for the base class template<class V, class I =int> class Array{ private: vector<V> myStore; public: Array(); Array(I size); Array(I size, V value); …

Member Avatar for abhimanipal
0
248
Member Avatar for lovelyv

So this is what i need to do and its not coming out right in my code. i need A function to calculate how long the balance will take to grow to a given value. This function is not part of the account class. It should take two arguments: an …

Member Avatar for lovelyv
0
382
Member Avatar for cambalinho

i build these code. it's very cool: in test.h: class test { private: bool blVisible; int x=0,y=0; public: void Show(); bool Visible() { return blVisible; } void Visible(bool value) { blVisible=value; if (value==true) Show();//call the event } }; in main.cpp: include <iostream> #include "test.h" using namespace std; test a; void …

Member Avatar for cambalinho
0
230
Member Avatar for cambalinho
Member Avatar for cambalinho

the Visual Studio 2010 have 1 way for build properties, in class's. but isn't a portable code:( i'm using GNU\GCC\G++. so don't belive that isn't possible do it in C++;) so anyone can advice me? i was testing these code, but i get problems with char* and i can't use …

Member Avatar for cambalinho
0
332
Member Avatar for Luckychap

Here is simple Digital Clock coded in C++ and compiler used is TurboC. A class DIGIT is designed to draw digits. Follwoing are the details for this class: Consructor: DIDGT(); for default settings DIGITE(int s,int c,int st); for user define settings s -> is size of the digit c -> …

Member Avatar for irum.nageen.3
-2
15K
Member Avatar for abhimanipal

Hi Guys, I am trying to teach myself templates in C++. My current assignment is to create a matrix class by using vector of vectors. I have got most of it done but my code is crashing when I try to overload the random access operator in my matrix class. …

Member Avatar for deceptikon
0
442
Member Avatar for skyyadav

Write a minimal terminal emulator which will basically just transmit all characters typed on the keyboard to the serial port and display all characters received via the serial port. Include a set of menu items that will allow a user to:  Select, modify or set the communication parameters such …

Member Avatar for Ancient Dragon
0
226
Member Avatar for TalentedIndividual

Im having a few problems developing an algorithm to find the Minimum subsequence sum. Can anyone offer any advice?

Member Avatar for phorce
0
69
Member Avatar for younes.keraressi

![![hi, im wondring why i get this error here my code: #include <iostream> #include "Stuff.cpp" using namespace std; int main() { //... } //Stuff.cpp #include <iostream> #include <string> using namespace std; bool Correct_Parent(string x) { int p_Left_Counter = 0; int p_Right_Counter = 0; for(unsigned int c = 0; c < …

Member Avatar for younes.keraressi
0
195
Member Avatar for k88joshi

Hi all, I am fairly new to C++, but i am having trouble declaring a 2D dynamic array. Any help will be appreciated. Thanks

Member Avatar for cambalinho
0
738
Member Avatar for gneisler

The code on lines 44-53 is suppose to check see if the user enter a negative and produce a message, however, when the use enters a positive code produces the display again. #include<iostream> #include<cctype> using namespace std; int main() { char carType; int A, B, C; char keepgoing; char condition; …

Member Avatar for cambalinho
0
141
Member Avatar for cambalinho

i'm trying doing a static clas, but i, always get errors... now i have head pain:( class Pessoa2 { private: static string strnome; public: Pessoa2() { strnome="ana"; } void setnome(string value) { strnome=value; } static string getnome() { return strnome; } }; just seen these static class, what i'm doing …

Member Avatar for cambalinho
0
211
Member Avatar for cambalinho

i read several time about Bitwise Right Shift Operator (>>\<<) but i continue without understand them:( can anyone explain to me? i don't undertand what will be the next results:( Half = 25 >> 1; Half = 25 << 1;

Member Avatar for cambalinho
0
387
Member Avatar for anga08628

Define a 5 x10 2-dimensional array of integers (5 rows of 10 columns), randomly generate 50 numbers between 1 and 100, assign them to the array elements and display all the numbers on 5 lines of 10 integers each. [code=cpp] #include <iostream> #include <ctime> // For time() #include <cstdlib> // …

Member Avatar for irum.nageen.3
0
11K
Member Avatar for weathermans

Hi, looking for help on how to get data from an xml file, or txt file and then automaticly send it over the serial port. I am looking to program a sports score ticker

Member Avatar for Ancient Dragon
0
253
Member Avatar for weathermans

Hello I'm looking for some help on how to get a XML value which would be one word. Then take that value and output it in a C# or C++ program. Using windows 7 and visual studio 2010. I have Novice programming knowledge. Thanks for help.

0
151
Member Avatar for donlxu

Hi. I'm trying to create a program to compute the Riemann zeta function which is defined as **1**+**(1/(2^x))**+**(1/(3^x))**+**(1/(4^x))**+.... for user input of x and will keep adding as long as the term is less than (1e-7). but I keep getting 1.79301e-307 for every number I put #pragma hdrstop #include <iostream> …

Member Avatar for donlxu
0
194
Member Avatar for sportguy98

Hello everyone, I am having trouble with an assignment. The assignment consists of a basic encryption and decryption program already written for me, I just have to write the encryption function. What we have to get the program to do is enter an integer and a text, and get the …

Member Avatar for ddanbe
0
186
Member Avatar for sudesh.yadav.104

I want to create two textboxes on my window. I used this code case WM_CREATE: hwnd = CreateWindowEx(WS_EX_CLIENTEDGE, TEXT("edit"), TEXT("sending"), WS_CHILD | WS_VISIBLE | WS_TABSTOP | WS_BORDER | ES_LEFT, 15, 15, 200, 300, hwnd, NULL, NULL, NULL); hwnd = CreateWindowEx(WS_EX_CLIENTEDGE, TEXT("edit"), TEXT("Receiving"), WS_CHILD | WS_VISIBLE | WS_BORDER, 220, 15, 100, …

Member Avatar for sudesh.yadav.104
0
213
Member Avatar for DeanMSands3

Name says it all. Is it still relevant? I guess wxPython sort of counts. What do you think Daniweb? Now, I don't want to start a flame war -said every troll ever.

Member Avatar for mike_2000_17
0
162
Member Avatar for nathan.pavlovsky

Hello programmers! I am making a player vs. computer Tic-Tac-Toe game in xCode that is a class, with its `run()` method as its only public member function apart from the initializer. I want to decide whether the player goes first, and I created a function to do that called `determineFirst()`. …

Member Avatar for nathan.pavlovsky
0
130
Member Avatar for disha malik

how to write a program to get a result.... 1 1 121 12321 1234321 by usingfor loop

Member Avatar for rishif2
-1
86
Member Avatar for zuki88

#include <iostream> #include <string> #include <stdlib.h> #include <winsock.h>//dont forget to add wsock32.lib to linker dependencies using namespace std; #define BUFFERSIZE 1024 void die_with_error(char *errorMessage); void die_with_wserror(char *errorMessage); int main(int argc, char *argv[]) { string request; string response; int resp_leng; char buffer[BUFFERSIZE]; struct sockaddr_in serveraddr; int sock; WSADATA wsaData; char *ipaddress …

Member Avatar for zuki88
0
130

The End.