49,761 Topics

Member Avatar for
Member Avatar for pjawili18

Hello, I'm writing a c++ code that reads a wav file and stores read values to a 1D array of integers. After doing some manipulation, I am able to write the values of the array to a new output wav. I use libsndfile library to do the reading and writing …

Member Avatar for Cesko82
0
472
Member Avatar for Stefano Mtangoo

Hi, I need to make application that will act as server and have clients. computers with client will get permission to go to internet or not via server. Only permission to go but they will connect directly on net (not a firewall). Its some sort of internet cafe management depending …

Member Avatar for Stefano Mtangoo
0
103
Member Avatar for malinik

Hi, Hope the stated 2 snippets are logically same. But I am getting error for the second code snippet. Generally the ternary operator statement is similar to a if else statement. regarding the second code snippet, where by the continue keyword is used in the ternary opertor statement. It throws …

Member Avatar for malinik
0
113
Member Avatar for bbrradd

heres my code. i need a triangle that looks like: **** _ *** __** ___* but mine looks like: **** *** ** * can anyone help ? [CODE]void drawTriangle(){ //function to hold triangle code char c; //variable to hold character to make triangle int height; //variable to hold height of …

Member Avatar for WaltP
0
126
Member Avatar for Web_Sailor

Hi, I am trying to compare 2 vectors to remove any kind of overlap. I have written a simple program but it gives a segmentation fault once I increase / decrease number of vector elements in both. Is there a better way of doing this. Especially suppose one of the …

Member Avatar for Web_Sailor
0
174
Member Avatar for ETP

Rational fractions are of the form a/b, where a and b are integers and b≠0. Suppose a / b and c / d are fractions. Arithmetic operations on fractions are defined by the following rules: a/b + c/d = (ad + bc) / bd a/b – c/d = (ad – …

Member Avatar for WaltP
0
153
Member Avatar for Menathradon

Hello All, I seem to be having a relatively small problem with a Maze program I'm working on. Basically, I read a txt file containing a maze into a 12 x 12 2D array, but the problem is when I try to display it, none of the white spaces that …

Member Avatar for WaltP
0
2K
Member Avatar for loststudent88

Hello I am working on a program and have become pretty confused... I am supposed to write a program that will convert html colours expressed as 6 hexadecimal digits to their individual red, green, and blue components expressed in decimal. If anyone can help me out with some pointers of …

Member Avatar for mrnutty
0
296
Member Avatar for megmar

I am looking to take a course in C++, but is that language popular now, or is everything more C? Please advise.

Member Avatar for kendricktamis
0
106
Member Avatar for kikat

I need to print the level order traversal of an AVL tree. I know how the idea works using a queue: enqueue the node, and then enqueue the left and right nodes of it. every node has a int data which needs to be printed but then the thing is …

Member Avatar for mrnutty
0
115
Member Avatar for Stefano Mtangoo

Hi, I'm finding generic container like vector but that can hold any variable just like a Python list. Thanks

Member Avatar for Stefano Mtangoo
0
84
Member Avatar for InnocentVamp

Hey friends, I want to know how does the IP Messenger work? How does it detect all the available online users? I searched on the web but due to Cyberoam restriction, I am left with very few options. I go by IP Addresses too, but even then I am not …

0
45
Member Avatar for blakenbama

Hello everyone, I need help. In my assignment i have an input file that contains string data: ----> i love music and chicken. today is the first day of the rest of your life. my name is john. I must change it to the following in the output file: ----> …

Member Avatar for Ancient Dragon
0
139
Member Avatar for elainadani

I need to create a function that uses a loop. This function will open a text file and then must be able to skip a variable number of leading random integers. The program must be able to handle any number of leading random integers. Example if the opened file reads …

Member Avatar for Ancient Dragon
0
150
Member Avatar for clutchkiller

Why are you able to declare them using the class keyword or typename keyword? Is there absolutley no difference? Thanks

Member Avatar for mrnutty
0
120
Member Avatar for Tech B

I downloaded a dll for head tracking, and have been trying to use it for some time now. I am trying to make a python script that uses it and am getting errors. [URL="http://www.daniweb.com/forums/thread265466.html"]This is the post.[/URL] I posted it in the python forums, and no replies yet, since this …

Member Avatar for Tech B
0
108
Member Avatar for jjmy95

I have an array of 20 elements with numbers between 1 and 8. I need a for loop that will give me the number of elements greater than 1???

Member Avatar for Grn Xtrm
0
139
Member Avatar for Flow2

Now I am on my way to making a little command prompt program where it types out the alphabet and removes the vowels as a test. BUT, here's the thing, no errors nothing but it doesn't work. Anyway here is the code if anyone can tell me what is wrong …

Member Avatar for Flow2
0
150
Member Avatar for ajjg123

Here is the prompt for my assignment Your third assignment is to write a C++ program that will print out the primes numbers between 2 and 100. However, you must use two functions in your program. The first function, factor, takes an int, n, and returns two factors of n …

Member Avatar for Lerner
0
143
Member Avatar for 'AnKo

Hello all! This is my first post to community! I've been writing a program in C++ (not MFC) to get a NTFS ADS file and copy it to desktop. If you don't know what ADS file is, you don't really have to matter, let's say that this program must just …

Member Avatar for 'AnKo
0
321
Member Avatar for Nicky4815

Hi all, I'm doing a 3d pacman game for a university project which has to be written in c++ (3rd year and having never been taught any c++) My problem is that when I initialise the map array I cannot return the value back to the main method. The values …

Member Avatar for Salem
0
101
Member Avatar for Candi~

Hi everybody, my name is Candi and I am new here, I was lucky enough to find this forum. I am new to C++ and am teaching myself because I can't afford school at this time, all I can afford is second hand books :( and I am having a …

Member Avatar for Fbody
0
136
Member Avatar for bluerosebuddha

Hello, Can someone break down what this array loop means exactly? Mathematically I can't make any sense of it. I've reread this section of my book multiple times, but it's not sinking in. [code] int alpha[a]; int j; for(j = 0; j< 5; j++) { alpha[j] = 2 * j; …

Member Avatar for M.FARAG
0
147
Member Avatar for endframe

Hello all, like always : D I'm working on a structure program that has an array [B](m)[/B] that asks the user to enter its values, and then it transfers the even numbers to an array [B](even)[/B] and the odd to another [B](odd)[/B]. Both[B] (evan)[/B] and [B](odd) [/B]arays are in a …

Member Avatar for endframe
0
115
Member Avatar for aditya.kaole

Hi, Need some help regarding the macro usage. I've a case where the parameter to be passed to the macro function is not known till the point it is called. example: (continuing the example quoted below) - number "12" passed to the " DEFINE_FUNC( n )" macro is determined at …

Member Avatar for Salem
0
92
Member Avatar for theonlywalks

Hey everyone, I have a simple simple problem that is literally driving me insane. Basically, I have a database of numbers seperated my spaces. I just took a segment of my code because I am soooo completely lost with the output!! If the database is: 1 2 3 9 7 …

Member Avatar for Dave Sinkula
0
131
Member Avatar for tom384

Hi guys, I'm having trouble using a pointer to a vector<float>, it doesn't seems to be responding as I'm expecting it to. Probably a silly mistake on my behalf, but would anyone kindly point it out please. [code] vector<float>* t_matrix; ... cout << "get_t_matrices 0: " << Character::anim.get_animations()[j].get_t_matrices()[0].size() << endl; …

Member Avatar for mattjbond
0
192
Member Avatar for jakesee

Hi, May I ask what is the correct syntax to achieve the following function pointer pattern? I keep getting error C2064: term does not evaluate to a function taking 0 arguments Thank you. [CODE] class Apple { public: Apple(int i) { if(i == 1) { juicer = &Apple::one; } else …

Member Avatar for mattjbond
0
147
Member Avatar for Index

Hi! I would like to split vector elements into the two vectors. One output vector shall contain elements that, for instance, are odd, and another output vector shall contain even elements (actually the case is more complicated;). I wrote something like this: [CODE] typedef vector<int> ItemVec; static bool isOdd(const int …

Member Avatar for Index
0
1K
Member Avatar for mischikun

I'm having a bit of a problem with a group project. We're supposed to use linked lists in it and I've already created classes for the nodes for the linked lists. The only problem is that I need to make the class point to itself but I'm not sure how …

Member Avatar for Murtan
0
181

The End.