49,766 Topics

Member Avatar for
Member Avatar for shouvik

Hi people. well after I started learning C++ I thought why not try out my skills in some programming so I made my first programme. It is a very basic game commonly known as "HANGMAN" to many. It still might have some errors but it works. Hope you can modify …

Member Avatar for raptr_dflo
0
552
Member Avatar for az.rathore

hi i am new to c++ i have problem to solve kindly help me Start with any positive number n. If n is even divide it by 2, if n is odd multiply by 3 and add 1. Repeat until n becomes 1.For example sequence that starts at n = …

Member Avatar for raptr_dflo
0
211
Member Avatar for vishwanath.m

Guys, i have a problem in insert a string in to a vector.To be clear enough i have insert "vishwanath" into a vector can any1 help...

Member Avatar for raptr_dflo
0
175
Member Avatar for FragSax

I'm having a small problem with a map format that I'm making. It's essentially simple a char*[32] with each line of characters being stored in it for instance here's a hard coded version of the map and how I'm storing it: [CODE]int main () { char *mapdata[32]; mapdata[0] = "1111111111111111111111111111111"; …

0
43
Member Avatar for sita12345

Having assertion failure while deleting an element from a vector.What are the causes of assertion failure?

Member Avatar for sita12345
0
365
Member Avatar for sunder6218

hey everyone, i have trying to build a aplication which takes hand gestures as input and performs corresponding mouse events as output using opencv inc/c++, but im having trouble implementing the hand detection and gesture recognition part.. so anyone can help me out..!!!

Member Avatar for Moschops
0
114
Member Avatar for fsefsef23

I'm trying to figure out where a proper place to put a comparison counter to count the number of 'comparisons' made in a quick sort is. This is my code so far, I have one counter where I think it should go, but I'm not sure if it should place …

Member Avatar for mzimmers
0
7K
Member Avatar for Vicky288

Hi, Below is the source file and make file I 'm using. while building I'm getting the below error in the console. From the error its evident that its unable to find function definition .Can anybody help me to fix this. Console output:- **** Build of configuration Debug for project …

Member Avatar for gusano79
0
2K
Member Avatar for yznk

I am writing code for reading a matrix from a file and deciding which type of relations it has. ie. Reflexive relation. However i am getting this error: error C2679: binary '<<' : no operator found which takes a right-hand operand of type 'Binary' (or there is no acceptable conversion) …

Member Avatar for gusano79
0
724
Member Avatar for smmcfarl

I am working on a binary search tree and have came across a few problems that I can not figure out how to correct and was wondering how to fix them. In my program I am adding, deleting, printing, updating, and counting the total number of nodes. The only things …

Member Avatar for smmcfarl
0
316
Member Avatar for zing14

I am having trouble finding out how to code this. I understand what each one is and know how to tell by looking but cannot figure out how to create functions to check whether it is either reflexive, symmetric, anti-symmetric, and/or transitive (it can be more than one). Here is …

Member Avatar for zing14
0
4K
Member Avatar for bad_dreams99

Hey All, Here is a really simple piece of code that works as a magic 8-ball program where the user types in a yes/no question and a random response is returned. This could be a good read for new C++ programmers (like me), as it covers a lot of basics: …

Member Avatar for samymcdonnell
0
6K
Member Avatar for triumphost

Trying to re-write a php function to C++ using boost.. I have NOT seen code for this anywhere on the net. I thought it was useful and I need it for C++ but I need help.. definition of the function in c++ [CODE] void preg(string pattern, string subject, string &matches, …

Member Avatar for vijayan121
0
224
Member Avatar for badnack

Hi at all, this is my first post on this forum, thus i think it's nice whether i introduce myself. My real name is Nilo Redini, i came from italy (Pisa), i'm 25 years old and i'm a computer engineer. It's a lot of time that i read this forum …

Member Avatar for badnack
0
652
Member Avatar for stereomatching

I like STL but the performance of the STL of visual C++ 2005 is not good enough, could I find some containers which looks like STL? Oops, I just found 1.48 release a brand new library--Container This library even support rvalue reference, so sweet. I love you, boost. Thanks

0
70
Member Avatar for Aghtar

Hello again. Well, I've been trying to get this to work, and I finally was able to combine two functions into one, but now I have to create a new function called FillTime() which will calculate the time to fill to fill the pool, though it seems that it doesnt …

Member Avatar for MandrewP
0
1K
Member Avatar for Johnnyj01

I am having trouble figuring out how to test 2 bools in a loop. This is an example. do { }while (!done || !validMove); [CODE] #include <iostream> #include <cmath> using namespace std; int main() { int number1, number2, total; bool done = false, validMove = false; do { cout << …

Member Avatar for Johnnyj01
0
108
Member Avatar for bmanzana

this worked a few times and now its not :( anny help would be greatly appretiated [CODE] #include <iostream> #include <string> using namespace std; string vowels(string str) { string vow = "aeiouAEIOU"; for(size_t i = 0; i <= str.length()+1; i++) { str.erase((str.find_first_of(vow)),1); } return str; } int main() { string …

Member Avatar for bmanzana
0
108
Member Avatar for jnmisa

I am also a New Learner, Base on the Request, This Simple Code would detect if a Number is Even or ODD number.... // This is to Detect Odd and Even Number [CODE] bool ValidateDegreeValue; // This is to Validate that the User Enter Number Data double DegreeValueNum; // This …

Member Avatar for jnmisa
0
172
Member Avatar for sushlet

[CODE] ifstream in_gradebook; ofstream out_gradebook; in_gradebook.open("gradeBook.txt"); out_gradebook.open("gradeBook_edit.txt"); while (???) //while int is being read { in_gradebook >> score; out_gradebook << score << " "; sum = sum + score; } average = sum / 10.0; out_gradebook << average << endl;[/CODE] Here is a small snippet of the code I have …

Member Avatar for sushlet
0
245
Member Avatar for astrolegacy

Colafone Corp, an internet service provider has just started operations in Fiji. They require a program that calculates and prints the bill for Colafone Corp’s clients. As such the Corporation has come to you to create such a program. The corporation offers two types of services plan: Broadband Lite and …

Member Avatar for astrolegacy
0
152
Member Avatar for skylinedrifter

hey guys need help... Declare an enumeration type consisting of the nine planets in their order by distance from the Sun (Mercury first, Pluto last). Write a value-returning function that converts the name of a planet of the enumeration type declared in Step 1 into the corresponding string. The planet …

Member Avatar for Clinton Portis
0
182
Member Avatar for skylinedrifter

Hey! so my teacher is forgin, as i am and i'm having trouble understanding what he says... here is an assignment i got and im not sure what exactly it's asking. Would be big help if any of you guys could figure out what the question is wanting me to …

Member Avatar for thines01
0
145
Member Avatar for mitee

Hi, I am new c++ programming and I need some help with my code. I am supposed to create a Hangman game with a file and your supposed to be able to write new words to the file etc... But I have problems with the code after the user have …

0
61
Member Avatar for xxunknown321

[COLOR="Red"]First off let me just say i don't want anyone to do my homework for me. I get a greater sense of satisfaction knowing that I did the work. with that being said I'm looking for some way to start or some input on what measures I should take while …

0
130
Member Avatar for BenzZz

I'm a complete beginner to c++ so this may be a really stupid question... Basically so far i have this: [CODE]s1Textbox->AppendText( gcnew String(ss.str().c_str()));[/CODE] Obviously the text being displayed keeps appending. I looked at all of the methods for text boxes on the API but couldn't find anything to set the …

Member Avatar for BenzZz
0
68
Member Avatar for becraxie

Hi, I really need help with my c++ assignments. Thank's to everyone who can help! Create a grading program that reads a file exam grades and computes the Average grade and the letter grade for each of 5 students. Each student has 4 exam grades. Letter grade: A => 90 …

Member Avatar for mathijs
0
534
Member Avatar for amras123

[CODE] package primecdesc; import java.util.Scanner; public class Primecdesc { public static void main(String[] args) { Scanner myScanner = new Scanner (System.in); int a,b=0,ctr=0, ktr=1; System.out.print("Enter a number: "); a = myScanner.nextInt(); while(b>=1001) { if (a%b==0) b++; ctr--; } /*for(b=1;b<=1001;b++) { if(a%b==0) ctr--; }*/ if(ctr==1) { System.out.println(a + " is a …

Member Avatar for WaltP
0
101
Member Avatar for maria536

Help with this code, I have to do a cafeteria survey with 20 students, see code and errors I get, thanks Dim studentRate(20) As Integer Dim counter As Integer Dim starCounter As Integer Dim frequencies(20) As String Dim phrase As String Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As …

Member Avatar for Moschops
0
191
Member Avatar for Aghtar

So the teacher told me to combine the two functions from the first code and i tried but it wont give me the correct answers. I cant seem to find the problem on it.. I cant seem to call the function on the second code.. thanks in advance. [CODE] #include …

Member Avatar for Moschops
0
123

The End.