49,756 Topics

Member Avatar for
Member Avatar for TheBeast32

Hi, I'm making a program that will get input from a user's microphone, send it to another user with a socket, and play it. It's like a VoIP thing. I can send data using a socket, but I have no idea how to get input from a microphone or play …

Member Avatar for nmaillet
0
53
Member Avatar for rosenberg_a

I have a problem in the book (not for homework) that says. List Reverse Modify the linked list class you created in the previous programming challenges by adding a member function named reverse that rearranges the nodes in the list so that their order is reversed. Demonstrate the function in …

Member Avatar for rosenberg_a
0
289
Member Avatar for hockeygoalieguy

Hi. I've been trying to find out how to use Gui in C++. I use Bloodshed Dev.-C++ and so far I haven't found anything on how to do it. Could someone please help?

Member Avatar for Freaky_Chris
0
164
Member Avatar for drjay1627

hey, given one side and an angle how do you calculate the other sides and angles in a right angle triangle in c++. I'm basically looking for an algorithm. Thanks drjay

Member Avatar for StuXYZ
0
110
Member Avatar for makimbo

Hi! I wrote this program to generate a keyboard determined random numbers. [code] #include <stdio.h> #include <stdlib.h> #include <time.h> int amount, aleatory_numbers; int array[70]; int counter=0; int generator () { printf ("Introduce the amount of numbers that you wish: "); scanf ("%d", &amount); srand ( time(NULL) ); do { aleatory_numbers …

Member Avatar for StuXYZ
0
109
Member Avatar for winrawr

I'm trying to use new but I can't seem to get it right... in this example I ask how many strings the user would want to input, then ask for each one, then echo them back. [code=c++] #include<iostream> using namespace std; int main(int argc, char** argv){ int num, i; char** …

Member Avatar for Freaky_Chris
0
129
Member Avatar for xtremerocker

My program needs to use exponents, however, double does not allot enough space for my numbers, is there another way to use the pow(x,y) function or is there another function for exponents that I'm overlooking? [CODE=cplusplus] #include <iostream> #include <cmath> using namespace std; int main(void) { int thresh = 10000; …

Member Avatar for xtremerocker
0
213
Member Avatar for winrawr

I'm trying to write a class that will read and organize the command line arguments of a program. Like, it will read -a as a 'switch', and --abcd as a 'switch' and you can define different switches as having parameters, so -a bc de fg will have bc and de …

Member Avatar for winrawr
0
103
Member Avatar for Gaytri Khanna

Why we use main() function in c and c++? please reaply as soon as possible.

Member Avatar for Salem
0
80
Member Avatar for NexusX

I'm trying to read a single letter from the beinging of a string that is generated from user input. Though it sounds childishly easy, I think I may seriously have a heart attack from trying to solve this problem. Example code follows: [code=CPP] #include <iostream> #include <string> #include <sstream> #include …

Member Avatar for WaltP
0
2K
Member Avatar for FrancisC07

hi guys..! i need some help on how can i print out the output of my program.. the problem is, it will only print out the first char of a characters and i don't know how to use the pointer using an multidimensional array. ex. input: jhonny output: j here's …

Member Avatar for zalezog
0
133
Member Avatar for booker

Hello everyone I am new to the forum I have a question. I created a method foo(ifstream &myfile) and works only if executed ones. In a loop or consequtively calls make the cerr call [code]int foo( ifstream &infile){ if (!infile) { cerr << "Unable to open file "; return -2; …

Member Avatar for vmanes
0
75
Member Avatar for massivefermion

Hello I wanna ask is it possible to to us vb for building a program's GUI and c++ for its coding?

Member Avatar for vmanes
0
169
Member Avatar for bclark8923

For a class project we are to implement four types of sorts that they give us, and for the most part i have that working, but i wanted to know what would be a good data structure to use? Atm im just making an array, if it fills up, i …

Member Avatar for h3xc0de
0
102
Member Avatar for tones1986

Hi All, I am working on a project and have come across a slight problem. I have a file i am reading in that consists of the following: John Smith 333222333 01/01/80 M z11119 cs111 2008 fall a cs222 2009 spring f The first line is the Students information, the …

Member Avatar for tones1986
0
233
Member Avatar for reaven

Hi am trying to make a simple application that write and read from and to a text file the problem is that i want to be able to aerch in the text file for an specific line. the text file is a list of words with a meaning each word, …

Member Avatar for Comatose
0
238
Member Avatar for mikhala99

This is homework and I am using a getfile that is just a 5 row 4 column list of numbers. I can get this program to compile and when I go to run it, I get my cout text output but without my numbers and the program crashes. I am …

Member Avatar for mikhala99
0
125
Member Avatar for telemachos9

Hello, I'm relatively new to c++, so I would appreciate any help. This must be a very basic issue, but how is it that one can assign a stuct or class member to a pointer instead of that structs or class member's address (via &)? (from stroustrup) [code] struct name{ …

Member Avatar for telemachos9
0
97
Member Avatar for slobo_n

Hi all. I have just started using Qt, and i can't find any primer on how to connect my Sql Server2008 database. What are the steps that i need to make, so my database is connected with Qt. Additional info: I'm using Qt 4.4.3 open source on Windows XP and …

Member Avatar for h3xc0de
0
85
Member Avatar for !CE-9

Hello, I'm trying to implement a system of resource managers. There's a ResourceManager template and its templated member function which will attempt to create a resource from whatever _Creator had been passed (if the given resource can use the given creator class). The _Creator is just an aggregation of information …

0
61
Member Avatar for AutoC

I have a code snippet that strangely works one way on a fedora 6 machine and another way on a fedora 8 machine. [code] void Form1::SendToApp() { vector<int> isciistream; vector<int> fontstream; cout<<"Entering Form1::SendToApp()"<<endl; isciistream=wwnd->OnOK(); isciistream.push_back(32); char str[255]=""; cout<<"Size of IsciiStream:"<<isciistream.size()<<endl; for (int i=0;i<(int)isciistream.size();i++) { sprintf(str,"%s%c",str,isciistream[i]); cout << "isciistream[i] :" << …

Member Avatar for AutoC
0
154
Member Avatar for Abuzer755

Hi Everybody, I am new to C++,but strongly it is recommended to learn C++ for its speed. That is why I'm here.Could you help me about it. Where do I should start from,read which book and etc. Thanks in advance.

Member Avatar for William Hemsworth
0
136
Member Avatar for axelgeorge

Hello everyone, I'm a moderately experienced C++ programmer who has decided its finally time to learn socket programming. I want to learn by writing a simple client/server pair of apps. The client will send a simple text string across the network to the server. So far, I've only worked on …

Member Avatar for Salem
0
76
Member Avatar for abhi.nalluri

I have implemented ReadFile function for reading data through SerialPort.When the other end is responding correctely my program is working fine. Sometimes when I dont get data from the other end my program hangs.For this I have implemented timeouts for Readfile function. But It doesnt seem to be working. My …

Member Avatar for abhi.nalluri
0
426
Member Avatar for Passiongamer25

I have a problem with my program and it has to do with my finding average function. The program goes like this: The program will grade a series of exams and then print a grade report for students in a course. Input: An instructor has a class of students each …

Member Avatar for Passiongamer25
0
177
Member Avatar for delerium12345

I'm having a lot of problems writing a program to open a file listing the grades of 4 students, all listed next to their names, and outputting an appended version of the file with the average of the scores next to the numbers on each line. it goes something like …

Member Avatar for h3xc0de
0
80
Member Avatar for NexusX

Hello, I'm having a great deal of trouble stemming from a part in my code where I have to convert an integer into a string so that I can concatenate it - the problem being that a variable is refusing to clear or re-write itself, instead it just appends the …

Member Avatar for NexusX
0
114
Member Avatar for VBNick

I have seen functions defined these two ways: function(type *variablename) function(type variablename&) I commonly use the first one to pass on pointers to my structs, but is the second one the same as the first?

Member Avatar for VBNick
0
306
Member Avatar for rosenberg_a

This is my code... [CODE] #include <iostream> #include <fstream> #include <vector> using namespace std; bool searchVect(vector<int>, int); int main() { bool answer; int value; vector<int> vect = {13579, 26791, 26792, 33445, 55555, 62483, 77777, 79422, 85647, 93121}; cout << "Enter the number to determine if there is a winner. \n"; …

Member Avatar for VernonDozier
0
134
Member Avatar for kishore84

Hello friends, Need help in generating a random number from an array.Once a number is generated, the number has to be deleted from the array so that only the remaining numbers can be generated from the array.And it should go on until all the numbers from the array are deleted. …

Member Avatar for VernonDozier
0
3K

The End.