49,761 Topics

Member Avatar for
Member Avatar for Stpdoug

Hey guys i am having a small problem with this calculation in bold: **amtwon = (pow(pbet,2) / pow(pbet,2-100 *pbet))** ; amtlost = ( 0.35 * pbet); totalwin = (amtwon - amtlost); this is the block of code.the problem is **amtwon** totalwin is supposed to return a value of 23.993.18 but …

Member Avatar for Stpdoug
0
284
Member Avatar for bladelord76

Hello, everyone! I just have a simple question, I think. I have created three unique classes, and each of these classes use some of the others as member variables. However, because of the way the code is organized, I often receive the error "CLASSNAME is not declared" when trying to …

Member Avatar for bladelord76
0
263
Member Avatar for rob.brown.315080

Hello all, I am trying to create a program which keeps track of football stats for individual players. The program is setup to read a list of players names, numbers, and positions from a .txt file and then put them into a strctured array, print them to the screen, and …

Member Avatar for WaltP
0
200
Member Avatar for PinoyDev

I have a program created in dev-C++. It works find and no errors but when I transfer to microsoft visual C++ express edition I got this error. "No such file or directory found for "windows.h". In dev-C++, I can found windows.h in C:\Dev-Cpp\include but not in Microsoft VC++. Whats the …

Member Avatar for Ancient Dragon
0
316
Member Avatar for krishal.lad

Can somebody tell me how to override a function by using the scope resolution operator ( :: )?

Member Avatar for triumphost
0
142
Member Avatar for daino

Would anyone know if there is a specific directory for any IDE, in this case I'm using DevC++ on Windows XP and have a button widget from WXWidgets which can contain a Bitmap Image (wxBitmapButton). I can't understand the documentation surrounding this control but all I want to do is …

Member Avatar for triumphost
0
194
Member Avatar for vougnne21
Member Avatar for orar

#include<iostream> using namespace std; #include<iostream> using namespace std; void main() { int a ,b,c; cout<< "Enter three integers"<<endl; cin>>a,b,c; if (a<b && a<c) cout<<"a is less"<<endl; if (b<c && b<a) cout<<("b is less"); if (c<a && c<b) cout<<"c is less"<<endl; else cout<<"all numbers are the same"<<endl; }; I GET A …

Member Avatar for np complete
0
277
Member Avatar for kshahnazari

Have a question , if we can compare two arrays for equality like this #include <iostream> using namespace std; int main() { int a[5],b[5]; for (int i=0;i<5;i++) { cin>>a[i]; cin>>b[i]; } if (a==b) cout<<"they are equal"; } as you see isnt there a way like this or a function to …

Member Avatar for L7Sqr
0
142
Member Avatar for Bumpehh

So, i wanna try graphics, and i was wondering if sfml or sdl is better? I cant find any good tutorials on sfml and its kinda confusing. i havent used sdl so im asking your opinion. and also, **What did you start off with, and why?**

Member Avatar for Bumpehh
0
122
Member Avatar for Sasquadge

Hey guys I'm having a minor issue here, I'm having an issue with my sterling.cpp in the add functions sterling add(sterling s1, sterling s2) my question is how do I get it to realize when my shillings is > 20 to goto pounds and when my pence is > 12 …

Member Avatar for Sasquadge
0
1K
Member Avatar for priyankakerala

I coudnot process video files in OpenCV 2.1. I hav OS x86 windows 7,Used visual studio 2010. When i first run a simple grab a frame from a video file (.avi) some missing dlls(msvcr90d.dll) error happened. Then I installed Visual Studio 2008 express. Then an another error happens R6034 , …

Member Avatar for np complete
0
179
Member Avatar for tspga

i want to display data from text file in list view and in tree view root will be file name, but i dont know how to do it, the problem is with displaying text file data in list view, i don't know anything about that. text file data is very …

Member Avatar for tspga
0
316
Member Avatar for Binary1010

Write a function, swapSubtrees, that swaps all of the left and right subtrees of a binary tree. Add this function to the class binaryTreeType and create a program to test this function. This was my assignment this week and I am just at a loss I don't even know where …

Member Avatar for Binary1010
0
919
Member Avatar for edgar5

I am converting an app I wrote when learning VB (I primarily use C++). In VB it was trivial to minimize a window to the Taskbar: Private Sub GoButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles GoButton.Click Me.WindowState = FormWindowState.Minimized Setting the window state in the "Go" button's _Click …

Member Avatar for edgar5
0
207
Member Avatar for kshahnazari

Im training for olaympiad and need a little of your help to know useful functions that You use . one of an important things I need , Is that to take a number base 10 to base 2 for example : 66 (base 10) , 1000010 (base 2) if available …

Member Avatar for deceptikon
0
108
Member Avatar for stevensonnz

Basically the program is a database of student enrollments. I cannot get the the search delete/undelete and update functions to work and need help asap. Need to implement a bool field to the delete / undelete Please help #include <cstdlib> #include <iostream> #include <iomanip> #include <conio.h> #include <fstream> using namespace …

Member Avatar for np complete
0
11K
Member Avatar for Yusuke00

Determinate,if it's possible,p numbers of n binary digits,so any 2 of this numbers to match in exactly m positions.There must no be positions same digit to appear in all the p numbers. Restrictions 1 <= p <= 25 1 <= n <= 25 1 <= m <= n a number …

Member Avatar for Bob
0
229
Member Avatar for precision_lawns

A retail company must file a monthly sales tax report listing the sales for the month and the amount of sales tax collected. Write a program that asks for the month, the year, and the total amount collected at the cash register (that is, product sales plus sales tax). The …

Member Avatar for Yusuke00
0
946
Member Avatar for Tinnin

Hi all. This regards chapter 6 of "Accelerated C++". The program is intended to scan a document and find all the urls in it. I am testing it with just one string input "text http://www.page.com more text". The program is compiling but doesn't run beyond me entering the input. I …

Member Avatar for Tinnin
0
282
Member Avatar for nagarjuna844

Hi, I'm new to C++. plzz help me with this error. #include <cstdlib> #include <iostream> #define clauselength 85 //we will use index number to find out the clause number. //there are 88 clauses. as we start using index from 1 we have to add one to 89. using namespace std; …

Member Avatar for np complete
0
326
Member Avatar for ilvanhellovan

can anyone help me,, i have some iteration that value from iteration store to 'List', the problem how to list of value from iteration and output as text file each line,, need your help.. thanks

Member Avatar for np complete
0
38
Member Avatar for rtyui

How can we know the name of the stream to which output is being redirected through a C++ program? For example, I have a program 1.cpp whose output is being redirected to a file a.txt i.e., a.out > a.txt Now, I want to know the name of the file to …

Member Avatar for L7Sqr
0
275
Member Avatar for Manchala

Hi friends i had a assignment to make this c++ program output f e d c b a e d c b a d c b a c b a b a a i have created this program using this code # include <iostream.h> # include <conio.h> void main(void) { …

Member Avatar for Ancient Dragon
0
205
Member Avatar for jonny93

I am trying to work on an assignment that allows you to create an entry for a phone book, but there are a few things confusing me: #include <string> #include <iostream> #include "entry.h" using namespace std; entry::entry() { p_fname = ""; p_lname = ""; p_phone = ""; } entry::entry(std::string fname, …

Member Avatar for jonny93
0
247
Member Avatar for XerX

Hello! Can someone please give me some advice where to begin this program from and how. Thanks in advance. [quote]Given set of points in the plane, you have to write a program in C++ that computes the following values: 1. The minimum distance between two points. 2. The maximum distance …

Member Avatar for Bob
0
634
Member Avatar for MrHatchi87

I'm stuck with this one. I need help drawing a tree in C++. Weird right? I've posted the parameters below and my response has my code so far. Write a program that draws a pine tree of a specified height How tall should the tree be?: 6 1. Prompt the …

Member Avatar for WaltP
0
2K
Member Avatar for haqua

**Hello C++/C Programmers there,** Please help with my program in C++, my program is always have 2 errors every time I compile and run it. My program is about string permutation which has main menu first. Here is my codes: #include<iostream.h> #include<conio.h> #include<stdio.h> int count=0; void permut(char stra1[],char append[]) { …

Member Avatar for WaltP
0
3K
Member Avatar for anumiqbal

kindly help me n tell me in 2 dimension array wen we r taking words as input then cin would be used or getch..???plz replay.me waiting

Member Avatar for WaltP
0
129
Member Avatar for dreday92

My program wont compile because of this one function, can someone explain to me why it is says "forbids comparison between pointer and integer" Any help would be appreciated void ReadBitPattern (ifstream& infile) { int x; x = cin.get(); if(cin.get() == "0") { for (int index = 0; index < …

Member Avatar for NathanOliver
0
102

The End.