49,761 Topics
| |
Hello all I am a beginner in image processing and would like to know how i could get the coordinates of an image which is displayed in a window. I work on the visual studio platform to implement my c++ codes. Could someone help me with this please Thanks in … | |
Hello, I am in the process of writing a board game, and part of that game involves having a user click on a hexagonal tile, and when they do and certain conditions are met, the tile should change color to match the player's color. Below is a sample program which … | |
I want to print out the letter B, instead I get a blank line. Any tips would be great [CODE] #include <iostream> using namespace std; void add(string n); int main() { string B; add(B); } void add(string n) { if(n.length() <= 1) { cout<<n[0]<<endl; } }[/CODE] | |
Hello everyone, I'm having a hard time figuring out what is wrong with my codes. I have a set of arrays and I have to sort them in order to find the median. I made the function to find the median and I tried recalling the function but it keeps … | |
I need help when i run the app. and enter the wrong answer "No. please try again " continues to loop forever . I want it to say it only once and repeat the same question. Any ideas? I thought maybe the braces were off somewhere but I'm not sure. … | |
[CODE]//Form1.h (Windows Forms Application) //.... //.... #pragma endregion cli::array <String^> ^sum; private: System::Void BtnComp_Click(System::Object^ sender, System::EventArgs^ e) { nocarrystate n; carrystate c; char a; states * curstate; states::init(&n, &c); String ^text1 = TxtBin1->Text; String ^text2 = TxtBin2->Text; curstate = &n; int i = 0; int len1 = text1->Length; sum = … | |
I am having trouble with generaetOutput function the void part is throwing me off. I tried to do it like the genrateQuestion function but the void part has me confused. Also my while statement is missing something because the error message continues to loop and if the user enters a … | |
I am writing code for homework. It is an inventory program using a stack class and a inventory class. When I complile I get the following error: Below is my code thus far. Error 2 error C2512: 'InventoryItem' : no appropriate default constructor available c:\inventory.cpp 17 chapter18 Here is my … | |
I think I may have bitten off more than I can chew with this. I'm writing a program that will figure out the last position standing by continuously counting the positions using prime numbers till only one is left. [url]http://acm.uva.es/p/v100/10015.html[/url] is a link to the original problem. the code I … | |
my problem stmt is as follows my input to the program is text file which contains records like 10 20 30 40 70 20 30 70 30 40 10 20 29 70 80 90 20 30 40 40 45 65 10 20 80 45 65 20 like this and i … | |
Hiii again i have done dis program but i get o/p like dis 1 2 3 4 5 6 7 8.... I need to get like dis 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21[code]#include<iostream> using namespace … | |
Device an algorithm to test whether the three numbers represents the side of a right angle triangle | |
Hello! I'm planning to make an online program, actually it would only be a login system with GUI and a chat window after login. The client program would recieve some data from the server (like names, ages, etc). I don't want to use C++ for sockets, I want to use … | |
I'm writing a game where I create a map using ncurses. What I want to try and do(if possible) is make the map the size of the terminal, in other words in the main program I have: [code=C++] // Create a game on an 80x30 map Game gameInstance( 80, 30 … | |
I am doing a project in Image Processing using C++. I need to get the RGBA values of a png image. I am able to get RGB values. but I couldnt get Alpha part. Pls help me out... Thanks in advance.. | |
I'm haveing trouble with this program I don't know what the problem is because my compiler says that their isn't one but the console says their is but it wont give me lines my code is very long too. [ICODE] #include <iostream> #include <fstream> #include <vector> #include "Clear.h" namespace fun{ … | |
Hi, I have written a program for reversing a digit but I get "error C2664: 'strcpy' : cannot convert parameter 2 from 'std::string' to 'const char *' Which I don't get since strcpy is supposed to change a string to a char array. Any clues for whats going on here? … | |
dears i'm new to c++ and i'm trying to make some demos application now i'm buildin an application that use http connection to make http request and get a return value from URL example: use [url]http://www.mywebsite.com/somthing.aspx[/url] this URL should returm a simple string value how i can read this value?? | |
Hey guys, sorry for the bad rep. But, recently i've obtained a code in c++ which highlights c# syntax in a Richtextbox. [URL="http://www.c-sharpcorner.com/UploadFile/duncanharris/SyntaxHighlightInRichTextBoxP212012005044912AM/SyntaxHighlightInRichTextBoxP2.aspx"]LINK[/URL] I think the basic idea behind it is to specify an array of strings, and now the program should search and highlight the defined strings in a … | |
can any one send me C++ code for 2-3-4 tree insertion, deletion and search code plz...[I]email snipped[/I] | |
I need to implement Huffman coding using a binary tree. I have successfully created the tree and have been able to execute the program by manually entering the characters and their frequencies but I now need to read the characters/frequencies from an input file and then output their matching Huffman … | |
I successfully had one enemy wandering back and forth in between collision blocks in my platform scroller. Unfortunately, I'm running into problems when trying to drop multiple enemies across the map. I basically made 7 additional enemies and gave them different starting positions across the map, but the program crashes … | |
Hi i have been following this tutorial [url]http://jnrdev.72dpiarmy.com/en/jnrdev3/[/url] in which all the code is supplied if you need to have a look. I am wanting to add another player- how would i go about doing this. I have a player.cpp and a player.h in which i think i need to … | |
How do you create a tile based collision detection map for visual C++? i have the code to implement it i now want to change the layout of the map | |
I am trying to create a function that takes in a sorted vector of integers, loops through the vector and if there is a value in the vector that is repeated it deletes that entry. This is what I have so far and I am not too sure how to … | |
In my header file I have: [CODE]#include <iostream> #include <string> using namespace std; class Customer { public: //Output void displayLabel(ostream &out);[/CODE] And in my main: [CODE]#include <iostream> #include <fstream> #include <string> #include <iomanip> #include "Customer.h" using namespace std; Customer cust; string blank = " "; string line; int start, end, … | |
Hi i am trying to make a jump and run game in Visual C++ using SDL I have been following a tutorial([url]http://jnrdev.72dpiarmy.com/[/url]) which was very good but finished before everything was covered. In a game lik mario, the players will navigate over jumps and onto ledges ect. I am using … | |
I just made a program that takes input from the parallel port(or printer port) of a computer and translates that input to English/Numbers. Its a Morse Code Transmitter translator and a Morse Code Calculator. Anyways, so I have to write a writeup about the program and I am kinda confused … | |
I'm trying to make the container to work with one of my classes. But i don't understand what should the overloaded operator contain. Maybe this is because i don't know the container too well... Please give me some insights. This is my class [code=C++] class Complex{ private: int re; int … |
The End.