49,761 Topics

Member Avatar for
Member Avatar for NinjaLink

My goal is to write a problem that will read in a length in feet and inches and output the equivalent length in meters and centimeters. As noted, There are 0.3048 meters in a foot, 100 centimeters in a meter, and 12 inches in a foot. I am only having …

Member Avatar for NinjaLink
0
135
Member Avatar for Black Magic

Just editing my calculator and looking at what functions math.h had and i came across pow, My program compiles and things like that so no error but if I'm not mistaken the answer is wrong. 6 ^ 1 = 6X6? = 36 (IS THAT CORRECT??) JUST IN MY PROGRAM IF …

Member Avatar for Black Magic
0
227
Member Avatar for followgoat

Hi, I am in an intro to C++ class, and need help with a homework. The below question requires us to allocate seats in the House for each state according to how large its population is. The entire problem is given all the way below. I have 2 queries: 1) …

Member Avatar for VernonDozier
0
84
Member Avatar for VernonDozier

Hi all, I am trying to install MySQL++ on Windows XP and use it. I was able to install it in Linux because the website: [url]http://tangentsoft.net/mysql++/[/url] provided an RPM that built the libraries for you. As far as I can tell, no such thing is supplied for Windows. Supposedly, MySQL++ …

Member Avatar for VernonDozier
0
295
Member Avatar for VernonDozier

Hi, I am working on a project wherein one program writes to a file, but allows a different program to read from that file BEFORE the first program is finished writing to it. In this project, the first program is a game. When someone scores in the game, that activity …

Member Avatar for VernonDozier
0
210
Member Avatar for guy40az

Can anyone tell me how I can read the resistance between pins 4 and 6 of the serial port using VB or c++?

Member Avatar for hammerhead
0
135
Member Avatar for BOTnPAID4

I wrote a program to calculate a loan, the program compiles and works fine, but I get an answer I do not understand. The answer comes out "$1.#J". I am pasting the code here I am using, I am not worried about the code it is a pretty simple set-up …

Member Avatar for Ancient Dragon
0
113
Member Avatar for tripjokers69

I have a two part assignment. Part one is to create a menu driven program using variables to do certain tasks. Part two is to convert the variables being used into 2 arrays. The code for part one is post below and works perfectly for everything that is required. My …

Member Avatar for tripjokers69
0
103
Member Avatar for donnerCobra

Hi everybody :) I have a big problem with embedded Python. I develop a plugin for a C++ application and want to "teach" this app Python Scripting, that users are able to script their own functions. the App = The C++ Application plugin = my plugin I develop for the …

Member Avatar for donnerCobra
0
199
Member Avatar for vijayan121
Member Avatar for David Wang

[B]Game I am about to make:[/B] Coins are randomly drawn from a set of possible coins and arranged in a line. Two players alternately remove and collect a coin from either end of the line. The game ends when all the coins are removed and collected by the two players. …

Member Avatar for Ancient Dragon
0
174
Member Avatar for edek

The program as it is generates: [ICODE]>Parent1 >Parent2 >In Child >Parent3 Successfull...[/ICODE] If I remove the comment from line 31 - just below "//THE PROBLEM:" so the "gets(buff);" is executed it gives: [ICODE]>Parent1 >Parent2[/ICODE] and... waits (both parent and child processes running - both waiting). I would like to be …

Member Avatar for vijayan121
0
258
Member Avatar for chihuyu

[code=cplusplus] #include<iostream> #include<string> #include<vector> using namespace std; int main() { string a; vector<string> b; vector< vector<string> > s; while(cin>>a) { b.push_back(a); s.push_back(b); cout<<s.size()<<endl;//A1 cout<<s[s.size()-1]<<endl;//A2 } return 0; } [/code] Any problems with this? If line A2 is deleleted,the program can run.So I think s does exist,but when I add line …

Member Avatar for mitrmkar
0
76
Member Avatar for Seamus McCarthy

Please help i'm trying to click on the screen just inside the box coordinates of (x,y) but it clicks everywhere on the screen!! [code=cplusplus] void cursorpoint() { #include "cursor.h" int x ; int y ; //x will have the x position and y will have the y position of mouse …

Member Avatar for Seamus McCarthy
0
143
Member Avatar for Black Magic

Hey, Say if i made a program where people could register a account, but if they closed the window, the program would close and not remember passwords yeah? Well if i used the open file etc could i save the password's to a file so it remembered them? Many Thanks. …

Member Avatar for Black Magic
0
75
Member Avatar for srinivasan34

Hi ALL I am Srinivasan S Saripalli. I have a VC++ doubt which I have notified below. Hope you can give me a solution. I have developed a ATL,COM 32-bit Service and in the Service I am implementing Timer functionality using either `SetWaitableTimer` or `CreateWaitableTimer`. When I compile my Service …

Member Avatar for caperjack
0
151
Member Avatar for AshishMehra

Hello All, I am trying to write a program that gets input from a USB Tv Tuner and records/captures images for further analysis. Could someone point me in the right direction and tell me what I need to do to enable my program to read in from a USB port …

Member Avatar for AshishMehra
0
87
Member Avatar for maysda19

I need help with adding a structure that allows user to enter name-score pairs. I also need help in modifing my sorting and average calculating functions so they take array of structures with each structure containing the name and score of a single student. In traversing the arrays, use pointers …

Member Avatar for Ancient Dragon
0
80
Member Avatar for rimmytose

Hi, first time poster here and I am trying to run the Twofish implementation that I found online. I have a very basic knowledge of C++ and I am only trying to get these files to run so that I can analyze encryption times and decryption times for a class …

Member Avatar for mitrmkar
0
106
Member Avatar for death_oclock

I'm writing a program that opens another console application with redirected input and output handles. I don't get any errors when I run this, but the console closes immediately, despite the system("pause") at the end. With the current solution, I have it redirecting to files, but another solution using pipes …

Member Avatar for death_oclock
0
271
Member Avatar for Aamit

[code] #include <stdio.h> #include <dos.h> #include <conio.h> int main() { int i; printf("CMOS Dump (format [address=value])"); for(i=0;i<128;i++) { outp(0x70,i); if(i%8==0)printf("\n"); printf(" [%2x=%2x] ",i,inp(0x71)); } } [/code] This program compile but not run ,it give runtime error. How to solve it??

Member Avatar for Salem
0
98
Member Avatar for Mark515

does anyone know the code to output "Wrong password final try" on a 2nd unsuccessful password input? and then make the program go back to the default start position for the program below? [code] #include <cstdio> #include <cstdlib> #include <iostream> using namespace std; static const int password=1705898; int main() { …

Member Avatar for Sky Diploma
0
89
Member Avatar for doddware

Hi everyone, Please bear with me this is my first post here at daniweb. I usually develop in C or assembly for embedded systems, but occasionally I have need to develop a PC application using C/C++ and have relied on Visual Studio C++ 6.0. Unfortunately I recently purchased a laptop …

Member Avatar for doddware
0
130
Member Avatar for Google Spider

Hi, I'm getting seg fault in this [code] #include <iostream> int main() { char *p; *p='w'; std::cout<<p; return 0; }[/code] I'm sure it is due to the line [code] *p='w';[/code] I interpret this line as [QUOTE]Value at address p = 'w'[/QUOTE]. I would like to hear an explanation on why …

Member Avatar for Google Spider
0
133
Member Avatar for CoAstroGeek

Python has some nice features for working with paths: [url]http://docs.python.org/lib/module-os.path.html[/url] Does anybody know of any C/C++ functions, techniques or libraries to do something similar? For example, if I'm passed a path on the commandline as such: x = "~/mystuff/../myfile.txt" In python I could get the absolute path as such: os.path.abspath( …

Member Avatar for vijayan121
0
179
Member Avatar for Ryuji5864

[code] #include "stdafx.h" #include <fstream> #include <iostream> #include <string> #include <cmath> #include <iomanip> using namespace std; const string ID = "- CS 1361, Spring 2008 - Lab 39"; void PrintDblArray (double[],int,ofstream&); int Smallest(double[],int); int main() { int i; double n, arr[50]; ifstream fin; ofstream fout; cout << "Running Lab 35 …

Member Avatar for Ancient Dragon
0
137
Member Avatar for picass0

i need to hash and generate a salt value of the password which input by user and save it to a file. i understand how to create a txt file, but i don understand how m i going to hash and generate a salt value from the user input? this …

0
61
Member Avatar for nurulshidanoni

i have this data..but how to sort the data in descending order together with the examid? [U]examid total[/U] 1: 25 2: 20 3: 46 4: 56 5: 12 6: 22 7: 20 8: 18

Member Avatar for localp
0
149
Member Avatar for ninjabreadman

Hello all, this is my first post here. I've been working as an assistant product manager at a software developer for 18 months, and I'm looking to put my resume out there within the next 6 months, as a either a product manager, or as an APM in a larger …

Member Avatar for ninjabreadman
0
84
Member Avatar for anifeelings

[B]Define the class Student which has name (char name[20]) and age(int). Define the default constructor, member functions get_data() for taking the name and age of the Student, print() for displaying the data of Student. i hv tried it.. am new to this language, am learning, this is what i had …

Member Avatar for Nick Evan
0
215

The End.