49,761 Topics
| |
i am using turbo c++ 3.0 but it has not good graphics.i try visual studio and dev c++ but its syntax is changed. i want a compiler that has same syntax like turboc++. plz name it and give me a dowload link for 64bit os. | |
#include<stdio.h> #include<conio.h> void main(void) {#include<stdio.h> #include<conio.h> void main(void) { clrscr(); int item,lb=0,ub=9,mid; int DATA[10]={1,2,3,4,5,6,7,8,9,10}; int beg=lb;int loc;int end=ub; mid=(beg+end/2); for(int i=0;i<10;i++) { printf("%d",DATA[i]); printf("\nEnter item"); scanf("%d",item); while(DATA[mid]!=item &&beg<=end) { if(item<DATA[mid]) end=mid-1; else beg=mid+1; } mid=(beg+end)/2; } if(DATA[mid]==item) { loc=mid; else printf("loc is %d",mid); else printf("loc is null"); } getche(); } | |
I want to convert some numbers to binary, octal, and hexadecimal.. for example: . DECIMAL......BINARY......OCTAL.....HEXADECIMAL ................................................................... 1.................00000001.....001.......1 2.................00000010.....002.......2 And so on.. | |
Dear Kind-Coders, I am trying to learn to use boost::shared_ptr to manage the lifetime of a DLL, but I am having a type conversion problem whilst setting it up. Please see the following code: #include <boost/make_shared.hpp> int main() { { class CMyClass { public: CMyClass() {} ~CMyClass() {} int MyInt; … | |
Well I just started C++ and I'm trying to run the basic "Hello World" program. But it didn't work i tried EVERYTHING i even clicked the delete button. But NOTHING I don't know how to run a C++ program. ;( So can you please help me? ;) | |
Write a C++ program to print out the value of sin(x) or cos(x) depending on a user input (1 = sin, 2 = cos)and continue the expansion until successive terms differ from each other by less than 0.0001 (in terms of absolute value). Report how many terms are necessary. | |
In function : node* insert_in_tree(int number,node* p_tree) { if(p_tree == 0) { node* newNode = new node; newNode->num = number; newNode->p_left = 0; newNode->p_right = 0; return newNode; } if(number < p_tree->num) { p_tree->p_left = insert_in_tree(number,p_tree->p_left); } else { p_tree->p_right = insert_in_tree(number,p_tree->p_right); } return p_tree; // refering to this } … | |
hay guys iam new to c++ programming studing for c++.com iam getting to a point that i wirte a program and it doesn't run and i can't find anything realted to it , to know where is the problem so that's the program // cin with strings #include <iostream> #include … | |
hi, i am begginer, want some help in following questions. 1.write a program for to store five values in array and print them using loop. 2.write a program for to store and display the 2D array. 3. print diagonal element of matrix. | |
Please help me to answer the following problems, I am new with the c++ code, Write a c++ program that may be use to compute the area of square (area=side*side) or a triangle (area=1/2*base*height). After prompting the user to type the first character of the figure name (S or T) … | |
I am new to socket programming.I am trying to send datagrams containing image data(jpg) from one host to another continuously.I want to use C++.I have not came across detailed steps on how to achieve this for images anywhere.can somebody explain or link me to such tutorials? | |
I get the algorithm and how binary trees should work but this I don't get : look at the basic binary tree insert function : node* insert_in_tree(int number,node* p_tree) { if(p_tree == 0) { node* newNode = new node; node->num = number; node->p_left = 0; node->p_right = 0; return newNode; … | |
I am using poco library to send a email first I installed the libraries on my ubuntu sudo apt-get install libpoco-dev code using namespace Poco::Net; int main (int argc, char **argv) { try { MailMessage msg; msg.addRecipient (MailRecipient (MailRecipient::PRIMARY_RECIPIENT, "john@gmail.com", "John")); msg.setSender ("Anthony Smiths <anthonysmiths5456@gmail.com>"); msg.setSubject ("sending a email using … | |
I have finished writting the code for my media player but it cannot display the current video on the imagebox dedicated to it. Can any one help? | |
I would like to search a file for whether certain words are present and extract the parts of the sentence that contain the words; I would like to find words that are a particular part of speech, and extract the part of the sentence from the word before the previously … | |
I want the text in a textbox "txtConvertedInches" to be selected when i press the radio button "rbFromInches". private: System::Void rbFromInches_CheckedChanged(System::Object^ sender, System::EventArgs^ e) { bConvertingToInches = !rbFromInches->Checked; ToggleControls(); txtConvertedInches->SelectAll(); //I thought this would do it, but nothing happens } | |
Write a float function rectangle() that computes and returns the area of a rectangle using its two float formal parameters h and w, where h is the height and w is the width of the rectangle | |
I am having 4 errors with the main program and i dn't know how to slove it anyone to help me how to solve the errors and how the codes was suppose to be correctly typed: 1.error: 'salaried' was not declared in this scope (line 5) 2.error: expected primary expression … | |
I need help fixing my code. I'm getting the following errors: 107 C:\Dev-Cpp\TicketFineCalculator.cpp no matching function for call to `TicketFineCalculator::getFine(int&)' and note C:\Dev-Cpp\TicketFineCalculator.cpp:20 candidates are: int TicketFineCalculator::getFine(int, int, int, int) Here is my code: #include <iostream> //allows program to perform input and ouput #include <string> //allows string using namespace std; … | |
Hi all, I am working on Bank Management System,,i wanna connect my programm to MySql Can anyone refer me Book(s)/links where i can learn so...i have know how of Mysql already and worked on it | |
Hi every one i have a problem with this program the conslo window disappear automatically without waiting , Im using return 0; function but it does not work | |
I Want to know that what the difference between int and longint is Although they have the same siza (4 bytes) | |
We want to make a software with our neighborhood map and roads with directions. What would be the best way to do it? Its a university project. Platform would be Android and windows. | |
Just started learning c++ and ive got a bit stuck :L Im making a console application that injects a file into a process. The file name and process name are both specified at the start of the code using char FileToInject[] = "File_Name.xxx"; char ProcessName[] = "Process_Name.exe"; The console works … | |
func should take array and find a index of a target number : int find_index(int num,int Niz[],int index){ if(num == Niz[index]) return index; else if(num != Niz[index]){ find_index(num,Niz,index++); } else {return -1;} } I quess I know am accesing unacesable memory, just cant figure out where | |
i'm learning, by work, how use win32 forms applications. but i'm geting a problem: the label(STATIC class) is give me flickers :( i had tryied use the WS_EX_COMPOSITED but give me problems with WM_MOUSEMOVE message :( someone tell me something about double-buffering, but i only knows use it for images … | |
i am worried about my papers is there anyone who tch me C++ from begning |
The End.