49,761 Topics
| |
I cant get this code to work it searches and finds the answer, but it gets an error once you search it. Heres the assignment. [QUOTE]a.) Create a function called howMany that will search a two dimensional array for the the number of occurences a particular number is found within … | |
I don't knof if that's the right place, since it's not c++ specific but a windows development doubt... (and sorry my english) My problem is kinda stupid, but i don't know whats happening, im tryng to show a popup menu when user press the righ mouse buttom, in the cursor … | |
Given this piece of code [CODE] void swap(int x, int y) { x= x + y; y= x - y; x= x - y; } main () { i = 1; a[0]=2; a[1]=1; a[2]=0; swap(i,a[i]); printf("%d %d %d %d\n", i, a[0], a[1], a[2]); swap(a[i], a[i]) printf("%d %d %d %d\n", i, … | |
Hi, why is it giving me the warning: deprecated conversion from string constant to ‘char*’ How may I fix this? Any help is welcome [CODE=cpp] #include <iostream> using namespace std; class Melarki { public: Melarki(): first(""){}; Melarki(char * mimi): first(mimi){}; ~Melarki(){delete first;}; char * first; }; int main() { Melarki … | |
I have to create a program for a Jewerly Store, that is a markup application that accepts the name of an item (string), the quantity, and the wholesale cost. The markup is based on the name of the item. The program needs to output a welcome statement, accept an unknown … | |
Hello.. This is what my program is suppose to do: -find length of list -check for empty list -insert in back of list -delete from front of list [B]I have everything done except finding the length of list and check for empty list.[/B] I need help getting the length of … | |
I found a quite interesting problem on the Internet, and of course, out of curiosity, I tried to solve it. Too bad nothing came to an end :(. The task was to count the alphabet's upper letters appearing in a given text and to print on the screen all the … | |
[ICODE]#include<iostream> using namespace std; class Point{ float x,y,z; public: Point(float f_x=1.0, float f_y=1.0, float f_z=1.0); void setXYZ(float X, float Y, float Z); void setX(float X); void setY(float Y); void setZ(float Z); void getXYZ(float &X, float &Y, float &Z); float getX(); float getY(); float getZ(); }; Point::Point(float f_x, float f_y, float … | |
I am using cin to input a single character from keyboard.The problem is that if 2 or more characters are entered then the rest of the characters are being considered as input for the further cin statements.Is there any way in which I can clear the inpu buffer memory after … | |
Write a C++ program that would be able to manipulate a list of fruits. First, create a link list that has this fruit list: [B]apple | banana | peach | apple | mango | durian | rambutan | kiwi[/B] i. Then, sort the fruits in alphabetical order and display the … | |
[code=cplusplus] template <class T> void trace(LogBuffer& msgBuffer, T& data) { data.trace(msgBuffer); } [/code] In the above template fuction we are using a generic class T, but when we are compiling on gcc4.1.3 compiler we ar getting the following error. error:request for member 'trace' in 'data', which is of non-class type … | |
hi guys i have a problem that asks me to work with a given structure and to set an array of 35 and initialize the elements. then i take a loop statement that will step through the entire array and display the contents of each element. since the question only … | |
i got the code for this problem but not able to find where i am wrong my problem is as follows Given an array of numbers, find the longest subsequence whose elements grow monotonically: 1 4 8 2 5 7 3 6 => 1 4 5 7 1 4 8 … | |
hello everyone in need of a little help here.i am beginner to programing and i have to produce a program that 1 outputs a message to the moniter asking the user their age as a whole number 2 use the input method to obtain a whole number from the user … | |
Friends, First off, I'd like to thank each one of you for setting up such a fantastic supporting network to help each other. Here's what I want to do and I think this is feasible but haven't done it myself as my focus can been more architecting web and DW … | |
Hi there, could anybody please do me a big favour and write a complete program in C++ with at least one example of using all interface functions of the specified below ADT ( Abstract Data Type) You should implement the stack ADT using the STL vector class. Thanks :) | |
Hi.I want to thank in advance for all replys. Well let's get to the problem. I need to a C++ code that will do the following: 1.User inputs a number 2.All digits of the number inputed not divisable by 2(odd numbers) must be multiplicated. (* operation ). 3.Show multiplication result. … | |
Hi, im having some problem while doing my assignment, i cant make my recursive function to loop as to get each digit from the number generated randomly. int random (int num) { srand (time (NULL)); num = rand(); cout << num << endl; if (num != 0) return num % … | |
When switch"ing" (....) If the user inputs 1, would you just use case 1: or case '1': thnks | |
problem is a little harder than I expected maybe b/c of the specifications of the problem. Help would be appreciated because I've turned this into a mess. Input is a command line argument representing int between 0 and 255 Output: convert string to binary and output as array of numbers … | |
When [code] using namespace std; [/code] are you able to overwrite it for a specific line e.g ios::app while using the fstream header? or does that mean i have to use std:: on everything else? thanks | |
Hi, I am currently developing CSP program for Vista and XP platform. I already have a CSP code, that can works fine in XP. But when it comes to Vista, it cannot work at all. Do you have any idea how to make the CSP code worsk in Vista platform? … | |
Hello is there fast way to convert c char** to std::string[] array without loop the char** ? | |
erm... anyone know what is this declaration mean? [CODE]#define LCD_DATA GPIO8->DR[0xFF<<2] /* Data bits D0 = P8.0 .. DB7 = P8.7 */ #define LCD_E GPIO9->DR[0x01<<2] /* Enable control */ #define LCD_RW GPIO9->DR[0x02<<2] /* Read/Write control */ #define LCD_RS GPIO9->DR[0x04<<2] /* Data/Instruction control */ #define LCD_CTRL GPIO9->DR[0x07<<2] /* All 3 control … | |
Hi everyone. I am new to DaniWeb, so I hope I am doing this right. I need to make a few programs for one of my classes. I understand the concepts, but there are a few points I do not understand. My questions are below, and I will bold what … | |
i am a newbie someone know where can download C++ installer? can send me the website? | |
I have some dll's which I would like to use in my program but the problem is that I donot know the functions name So I am not able to use them through loadlibrary function So how am I supposed to find the function names Please help | |
hey there... i was trying to gather some information for a project i'm currently doing by searching on google and i stumbled upon a thread reply here... it seems that you guys have a great knowledge on the matter to which i seek... my project involves creating a system by … | |
*Note: its not a fully functional hashTable for technical purposes My priority is to get it to store the strings properly. I approached this a different yet similar way to my other post and I have gotten much farther! The problem now is that my output prints duplicates each and … | |
Hello everyone, I am new to computer science, and thus far this semester I have not needed any help in writing a program even though I am stuck with a professor who struggles to get a clear point across. He is a great guy and tries to make sure we … |
The End.