49,761 Topics

Member Avatar for
Member Avatar for fsl4faisal

[CODE] #include<stdio.h> #include<conio.h> #include<stdio.h> void maketree(struct node**); void inorder(struct node**); struct node{ struct node *left; struct node *right; int data; } void main() { struct node *root; root=NULL; printf("Enter root"); maketree(&root); preorder(&root); getch(); } void maketree(struct node **root) { int num; struct node *temp; if(*root==NULL){ //printf("Enter number"); scanf("%d",&num); temp=(struct node*)malloc(sizeof(struct …

Member Avatar for gusano79
0
163
Member Avatar for vidyasmani

Hi all... I tried the following code in my Turbo C++ .. [CODE]int j=5; cout<<++j + ++j + j++;[/CODE] and got the result 20, as expected. But, when I replaced the code and assigned the same to another variable x, it gives result 21. ie, [CODE]int j=5,x; x= ++j + …

Member Avatar for arkoenig
0
102
Member Avatar for ganesh_IT

Hi guys, i try to write a containment program with Date and Time classes, i have problem in operator loading in Date_Time.[CODE] class Date{ short d, m ,y; public: Date(); Date(short date, short month, short year); ~Date(); short Day() const; short Month() const; short Year() const; };[/CODE] [CODE] Date operator+(Date …

0
58
Member Avatar for BryanMColeman

I am rewriting in Visual Studio 2008 c++ an application written in VB.NET that successfully connects to an oracle 10g database using OracleDataAccessClient.dll. I am trying to utilize the same dll in the c++ app though very unsuccessfully. In the project's Property Pages, I have successfully referenced the dll. In …

0
36
Member Avatar for yusuf.business

how to make our c++ application bootable ? so we can boot from usb .... ? please help my friends i have searched a lot on internet but couldn't find appropriate thing ? thanks in advance ?

Member Avatar for JasonHippy
0
221
Member Avatar for shizu

Hi.. I would like to use microsoft visual studio C++ 6.0 to build a execute file to detect whether network drive is connected and ready to used.. can anyone of you teach me how do I do this..?? my situation is I have 2 PC connect using LAN.. PC A …

Member Avatar for graphicequalise
0
744
Member Avatar for Antler

Hi! I created a primitive login system and am wondering if I could somehow not show the actual password and instead asterisk. Here is the code : [CODE]#include<iostream> #include<string> #include<vector> using namespace std; int main() { string username; string password; cout << "Do you want to register?" << endl; cout …

Member Avatar for jonsca
0
2K
Member Avatar for kirennian

Please note that I mean overlapping windows in a literal sense, not in the DWSTYLE sense listed within this very function. I've been having this problem for quite a while now whereby I create a number of windows using the above function and have been having issues with the main, …

Member Avatar for kirennian
0
521
Member Avatar for yusuf.business

Dear friends ? I have searched a lot on net but i couldn't get any best articles.. I want to use mysql in my c++ applications . please provide a detail procedure for using mysql as database in c++ ? thanks in advance ... ?

Member Avatar for yusuf.business
0
167
Member Avatar for ganesh_IT

Hi guys, pls somebody tell me the detailed concept of containment in c++. its urgent pls..................

Member Avatar for jonsca
0
75
Member Avatar for rootchord

I just recently finished my CIS101 and 201 classes for C++. My instructor says i show alot of promise and i really enjoy coding. but here is my problem: The semester is over and this next semester i won't be taking any CIS classes(need to get some general edu out …

Member Avatar for aslamnandyal
0
185
Member Avatar for coolbreeze

ill show the problem in the book first then ill tell you what i know. ___________________________________________________________________________ Then following formula gives the distance between two points (x1,y1) and (x2,y2) in the Cartesian plane: √ (x2-x1)^2 + (y2-y1)^2 its the distance formula..hard to type on here Given the center and a point …

Member Avatar for gurusaranya
0
1K
Member Avatar for +_+man
Member Avatar for ylin333
0
942
Member Avatar for old_jefrey

I started to do some reading about template, found interesting example [code] template <class T1, class T2> bool GetItUP (T1 a, T2 b) { return (a>b?a:b); } [/code] And the way to use it: [code] int _tmain(int argc, _TCHAR* argv[]) { int a = 20; float b = 23.90; GetItUP<int,float>(a,b); …

Member Avatar for mrnutty
0
102
Member Avatar for scar164

Hello all! So basically I start off with one array, then I run a function that takes 3 floats, puts those 3 floats into a temporary array, then it returns this new temporary array and where I call this fucntion, It looks like this: [CODE=c++] float array [] = { …

Member Avatar for mrnutty
0
218
Member Avatar for jay88121

Hi, I'm very new to C++ and i'm trying to find the best way to solve this problem: First, i want my program to generate a random 6 digit integer as a variable (i have this part done).This random integer is the variable [B]x[/B]. After that integer is done, the …

Member Avatar for jonsca
0
98
Member Avatar for joji86

Hi , I am trying to call c++ exe from java applet.For this purpose am using processbuilder.My code is as follows ProcessBuilder pb = new ProcessBuilder(s); Process process = pb.start(); final InputStream is = process.getInputStream(); OutputStream out = process.getOutputStream(); PrintWriter pw = new PrintWriter(new BufferedWriter(new OutputStreamWriter(out))); pw.println(1); pw.println(1 +"" +2); …

Member Avatar for NormR1
0
216
Member Avatar for albgran

Hi Guys I need to compile and run a c++ program from java using Process a = Runtime.getRuntime().exec ("g++ -g function.cpp -o function"); Process b = Runtime.getRuntime().exec ("./function"); the problem is that the output I get from the c++ program is not correct but If I compile and run it …

Member Avatar for NormR1
0
105
Member Avatar for katokato

im trying to learn c++, so i stumble upon this programming exercise that asks the user to make a program that asks for 2 numbers, assuming that the second number is always the biggest in value, and adds all of the numbers in between the numbers entered including the entered …

Member Avatar for katokato
0
92
Member Avatar for tundra010

Just recently, I have upgraded from gcc 3 to gcc 4.5.0. However, when I try to compile a basic "hello world" example in c++, I get the following warning: Info: resolving std::cout by linking to __imp___ZSt4cout (auto-import) c:/mingw/bin/../lib/gcc/mingw32/4.5.0/../../../../mingw32/bin/ld.exe: warning: a uto-importing has been activated without --enable-auto-import specified on the c …

Member Avatar for tundra010
0
128
Member Avatar for smoothe19

1. My bigInt multiplication [B]does not work correctly [/B]it gives me the wrong output. 2. Also how do i modify the class BigInt to process both positive and negative large integers? Merci beaucoup to anyone that helps! Here is my code BigInt.h [CODE]/*-- BigInt.h ------------------------------------------------------------- This header file defines the …

0
74
Member Avatar for scar164

Hello all! I am trying to create a simple app that takes something from an mysql database and prints it, I had some problems with the libraries at first, but now it compiles and shows me the black console window, but then suddenly it gives me some errors and in …

Member Avatar for Ancient Dragon
0
214
Member Avatar for Andreas5

Hey, i have read "Accelerated C++" and i am "soon" done with "The C++ Standard Library". I would like to learn about Windows Forms Applications or something similiar where i can start creating more useful programs. Can anyone recommend anything? Is it too early for me to jump to this?

Member Avatar for Andreas5
0
121
Member Avatar for TheWeakGetEaten

I am learning stacks, and I am trying to get this program to work. I have to be able to add large integers such as 9999999999999999999999999 by pushing all the numbers on the stack and then adding them up. Currently it works with small numbers but large numbers it crashes. …

Member Avatar for bondgirl
0
1K
Member Avatar for Docbyte

I am new to C++ and have a problem in a class I am taking.I am having trouble trying to create this the way my professor wants. this is what is required from the program: Write a complete program that prints out a “tree” of asterisks with the number of …

Member Avatar for Docbyte
0
161
Member Avatar for louisdinh

I wrote the tic tac toe with minimax algorithm. However, there are some bugs that i cannot figure out why the computer cannot win the human. Please help me to fix it. Thanks. I upload a zip of all files for you to check it easier. I guarantee that it …

Member Avatar for louisdinh
1
2K
Member Avatar for elsiekins

This may sound like a silly question but does when using aType is it just means any type ??

Member Avatar for mrnutty
0
95
Member Avatar for livestrong2431

I know this is a horrible way to do this, but I'm trying to test out several things that I've learned at once in this code. It's meant to ask you how many numbers you want to add using dynamic memory, then push them on to the stack, and add …

Member Avatar for livestrong2431
0
135
Member Avatar for Deep Thought

Hi Have been using OpenGL with Borland C++ Builder 4 for about 10 years but need to port across to Embarcadero C++ Builder 2010 and am developing on generous W7x64 platform. I cant remember where I downloaded the original package from but I need a new package containing the right …

0
56
Member Avatar for nu2cpp

Hi Guys, I need some help in accessing elements from a list. I am using Visual Studio 2008 (c++). Here's my code: [CODE] using namespace System::Collections::Generic; public ref class Cord { public: int numCord; public: int x, y, z; }; public ref class Poly { public: Cord c1, c2, c3; …

Member Avatar for mike_2000_17
0
211

The End.