49,766 Topics
![]() | |
I have a function to detect if the mouse is over a mesh but what if I had a hard coded square. I am using D3DXIntersectTri() and pluggin my vertices into it. but they (obviously) dont update when I move the square. My question is how do you get the … | |
I have searched on the internet for a 'working' double to char* does anyone have any idea? I need to pass the string to a function that takes a char* as an argument. | |
HI, I AM THOMAS. I AM IN A COMPUTER PROGRAMMING CLASS AND HAVE BEEN GIVEN AN ASSIGNMENT. I HAVE TRIED TO FIGURE IT OUT FOR A WEEK WITH NO SUCCESS, READ DIFFERENT BOOKS AND VISITED VARIOUS WEBSITES IN VAIN.I HOPE I LANDED THE RIGHT PLATFORM TO HELP ME OUT. THE … | |
how i do this problem, i dont understand this problem plz everyone can help me Write a grading program for a class with the following grading policies: a. There are two quizzes, each graded on the basis of 10 points. b. There is one midterm exam and one final exam, … | |
I am trying to make a program that will check the remaining number of an item left in stock and that will, if someone buys it, subtract the amount of the item bought and then re-write it into the database... (Something like what they use in some stores) How do … | |
Can someone help me with a funtion that find a string in another one ? the example is string a= "hello how arsdddf" , b = arsdd ; I want a funtion that if b exists in a gives me the number that begins with it like it must give … | |
I want to know how exactly to add the button at the top of the search to note as the search criteria is for example asc to desc or vise versa  that is here i need a icon beside the colors to show me when i search weather … | |
This is what i have so far guys, //LAB 6 #include <iostream> #include <cmath> using namespace std; double getSides () { double sideA, sideB, sideC; cout << "Enter three sides: " << endl; cin >> sideA >> sideB >> sideC; } bool formTriTest (double sideA, double sideB, double sideC) { … | |
Hello, i have got no expereince at all with c++.. im just adding something to the source of my private server and i failed to do so because of the fact that it wasn't a tutorial on how to add it (just a release) so here is the error: error … | |
I need a way to return the maximum value of five numbers This is the explanation •function -- identify the maximum value of the five integers â—¦function name: maxValue â—¦function parameters: five integers, pass-by-value â—¦function return: the maximum value of the five integers, as an integer This is what I … | |
Example: #include<iostream> using namespace std; enum e_UserName { planet1, planet2, planet3, planet4, planet5, planet6, planet7 }; enum e_ServerName1 { Venus = 11, Mars, earth }; enum e_ServerName2 { jupiter = 11, pluto, neptune, earth2 }; struct map { enum e_UserName eUserName; enum e_ServerName eServerName; }; struct map name[] = { … | |
I'm new at this. But I'm taking a class and I need to turn this in by Friday. Please help me. I can only use strings and arrays. My hangman program needs five things: 1. user is prompted for a word that is ten letters or less, or else the … | |
![]() | I keep receiving these error messages: Applicant.cpp:25:6: error: prototype for âvoid Applicant::setDeposit(char)â does not match any in class âApplicantâ Applicant.h:12:7: error: candidate is: void Applicant::setDeposit(bool) Applicant.cpp:29:6: error: prototype for âchar Applicant::getDeposit()â does not match any in class âApplicantâ Applicant.h:13:7: error: candidate is: bool Applicant::getDeposit() Applicant.cpp:71:5: error: prototype for âint Applicant::addPoints(int)â … ![]() |
Hi I would like to get some directions on where to look for in the way of getting a c++ profram to put hex values on a printer. I would also like to know if some one could guide me with a few examples. Regards GT | |
Hey, I've completed an assignment in visual studio and it gave me expected results for example 261. My university system uses g++ so i compiled the assignment with it and it gave me 262 and there the exact same files. If anyone has any suggestion and experiances like this please … | |
Hi, I am using RC4 to encrypt the data. It works fine. But I found that some encrypted values contains NULL character or other escape characters in result. Due to which when I read the string back to decrypt, does not give the whole string back but truncate the string. … | |
#include <iostream> #include <new> using namespace std; int main () { int i,n; int * p; cout << "How many numbers would you like to type? "; cin >> i; p= new (nothrow) int[i]; if (p == 0) cout << "Error: memory could not be allocated"; else { for (n=0; … | |
You are asked to write a program that manages a company's stock. To manage the stock the program need to keep track of item information, prices and quantities. A user should be able to adjust these values on selected items, draw reports and perform certain functions over all the data. … | |
Hi, I used to solve ACM problems, but I used old scanf & printf for input and output.But now i want to use C++ style IO. So, i picked a simple problem, and tried to convert its old style IO to new style IO. The problem : [URL="http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=996"]http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=996[/URL] (in summery, … | |
what are arrays in c++ programming how to do or what is meant by swaping? | |
hi all, I am working on C++ coding of fault simulation algorithm of a digital circuit . The first step involves parsing of netlist files. The sample netlist looks like - # Only 2,3 input gates considered ... INPUT(1) INPUT(2) INPUT(3) INPUT(6) INPUT(7) OUTPUT(22) OUTPUT(23) # comment here 10 = … | |
I'm flumoxed, how do people normally handle CBaseClass::operator== and CDerivedClass::operator== What I have done is illustrated below, but is it good valid C++? I compare the base class members first (using base class ==) and then the derived class members (the rest of the implementation of the derived class ==). … | |
PREHIT/0.05 RETRACT/0.05 $$ NO,>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ,SEARCH FOR A SURFACE ASSIGN/V4=0 ASSIGN/V2=.32 ASSIGN/XOLD=0 ASSIGN/V1=0.01 ASSIGN/V3=0.001 SRCH01 =LABEL/ PNT7B1 =FEAT/POINT,CARTESIAN THEO/<2.739,3.395,V2>,<1,0,0> ACTL/<2.7395,3.399,0.2218>,<1,0,0> MEAS/POINT,1 HIT/BASIC,NORMAL,<2.739,3.395,V2>,<1,0,0>,<2.7395,3.399,0.2218>,USE THEO=YES ENDMEAS/ ASSIGN/V4=V4+1 IF/XOLD < PNT7B1.X ASSIGN/XOLD=PNT7B1.X ASSIGN/V5= PNT7B1.Z END_IF/ IF/XOLD < PNT7B1.X + V3 ASSIGN/V2=V2 - V1 GOTO/SRCH01 END_IF/ ASSIGN/V2=V5 + V1 ASSIGN/XOLD=XOLD-.001 IF/V1 == .01 ASSIGN/V1=0.003 ASSIGN/V3=0.00015 … | |
I've been tryin to make a keylogger to see how C++ handles keystrokes and sends them. I've found some code online and modified it a bit but, this has limitations and isn't accurate enough (+ missing characters from non english keyboards). #include "stdafx.h" #include <iostream> #include <windows.h> #include <winuser.h> using … | |
I'm trying to flip an image which has its pixels stored in a vector. For some reason, when I try to flip it, the image gets distorted and gray/fuzzy. Any idea why? My code is as follows: void JNIData::FlipBytes(void*& Result, bool TopDown) { unsigned char* Pixels = &BufferPixels[0]; //vector of … | |
Hi there. I am trying to code a program to add or subtract two polynomials using linked lists. For ex. (+4x^2-2x^1) + (+2x^12-5x^5). So far I have a read function which takes in a string and uses substrings to take the coefficient and exponents and insert it to a node. … | |
Im having some trouble putting together a linked list implementation of a queue. I'm getting a segmentation fault, which I believe is due to my empty() function because in an attempt to fix my empty() function, I made it determine empty based on (current_size == 0) instead of (front_p == … | |
Please help me. I really need a source code of a game that works on dev c++ except for the games: snake, sudoku, crossword, tic tac toe and hangman. almost everything i got from sarching the net had errors.. it's a rush school work. please help me. thank you. | |
HI I would like to modify the following function so that it could take any of the operators such as +,-,* or /. I want to know if its possible to do this without having to write bunch of ifs and else to define each of the operators separatly like … | |
Here is my code... #include <iostream> #include <cstring> using namespace std; class employee{ public: char name[64]; long employee_id; float salary; void show_employee(void); }; }; { cout<<"Name:"<<name<<endl; cout<<"ID:"<<employee_id<<endl; cout<<"Salary:"<<salary<<endl; }; }; int main(void); { char str1[40]="employee worker"; char str2[40]="employee name"; char str3[40]="employee boss"; char atr4[40]="employee name"; strcpy (worker.name, "John Doe"); worker.employee_id … |
The End.