Beginners - October 2011 (Page 26)

by kw1991
having problem playing sound
 
im have trouble playing a sound when a press a button in my project heres the line of code im using: PlaySound(TEXT("drum.wav"), NULL, SND_ALIAS | SND_APPL...
[1 reply] : #include allows you to add header files to your code. A .lib is no... (by Moooce)
Struct declaration question?
 
Code 1 #include <iostream> #include <string> using namespace std; struct data { string name; }a,b; int main() { cin >> a.name; cout << a.name << endl...
[2 replies] Last: Thanx @Gaminic. (by radit91)
can i put anything for the "return" in the main function?
 
#include <iostream> class CHighScore { public: char mcaName ; int miScore; }; int main() { using namespace std; CHighScore qHighScore = {"Hwllo World", ...
[7 replies] Last: @questgulkan, thanx. Your explanation is abit complicated for me, but ... (by radit91)
by gh24
Quick Beginner Question
 
Hi Guys, This is a very quick question. I am using newmat so matrices can be used as if they are simple variables from my understanding. I am writing a rec...
[6 replies] Last: I used this for a reference as I've never used this algorithm before:... (by Mathhead200)
Bubble Sort code (Please help)
 
hello i am new here and i am also just a beginner in C++. I have made a bubble sort program but there seems to be a problem in it. it dose not seem to sort th...
[19 replies] Last: @People saying "Can't do BubbleSort with 1 loop because it's O(n²)": ... (by Gaminic)
by gh24
Help Creating A Random Matrix
 
Hi Guys, I am trying to create a random matrix where the user inputs the size and then the program outputs a square matrix that size but the values of the matr...
[5 replies] Last: If they need to be dynamically allocated at runtime then you can use t... (by Mathhead200)
by kw1991
reading from text file to find average number
 
i have a text file with 30 records of dates and numbers(rainfall) i want to find the average rainfall between two dates so i want to be able to enter two dates...
[14 replies] Last: report , iterate through the array by increasing i each time... N... (by Mathhead200)
Computer Shop Application.
 
Hey Guys. I'm new to this so can you help me out with my code here? #include <iostream.h> #include <conio.h> #include <windows.h> #include <stdlib.h> ...
[7 replies] Last: time_t startTime = time(); //do stuff that you want to time... time_... (by Mathhead200)
by Zortis
System()
 
What library (g++) is system() included in? How can I also get System to return whatever it was doing. E.G system("ping google.com"); I want it to...
[7 replies] Last: Obligatory link: http://www.cplusplus.com/forum/articles/11153/ (by Gaminic)
by mzd72
error
 
why does this code give -27 no it should answer yes what is wrong #include <iostream> #include <cmath> using namespace std; int main() { long double a,d...
[4 replies] Last: any help (by mzd72)
by ChueX
C++ project
 
Our group has to write a program that has Move,Delete,Copy,Insert, etc. It is like word processor but more sample than the real word processor. So I need some h...
[2 replies] Last: Can you show me couple lines of that? (by ChueX)
Calculating average from input file
 
Hello everyone. For an assignment I'm supposed to calculate and display the averages for test scores and drop the lowest test score in the process. Basically I ...
[6 replies] Last: Thanks for all your help tonight. You've got it fixed for me and I app... (by thechad90000)
question on lists in C++
 
Hi-- I am having trouble creating a list in C++ where each element of the list is an object of class credit. Looks to me like the program is having trouble wit...
[2 replies] Last: [quote=MSVC]error C2678: binary '!=' : no operator defined which takes... (by shacktar)
a question on libraries
 
ok so is it possible to make a game or engine(i know making an engine is alot of work but im willing) using 2 libraries at once (example SDL and opengl) j...
[1 reply] : Yes, it's possible and that wasn't a dumb question. That's a good move... (by shacktar)
getline() problem
 
over here in this code // example about structures #include <iostream> #include <string> #include <sstream> using namespace std; struct movies_t { s...
[1 reply] : does it always need a string not integer so we use string in the midd... (by shacktar)
array [variable] problem
 
I'm stumped. #include <iostream> using namespace std; //... //... struct function { int degree; float coeff ; float constant; } ax, bx, cx, dx...
[5 replies] Last: I just realized you might be talking about dynamic array allocation. I... (by stridexr)
by Ch1156
Allegro C++ Help
 
OK so im following this tutorial and i did everything he did and i get no errors but what happens is the player doesnt appear to move when i press the up down l...
[1 reply] : I'm assuming allegro.h is some game library. I probably won't be abl... (by stridexr)
Function Help
 
//The program will return true or false depending on //whether input is a valid LISP command, a command-line interpreter #include <iostream> #include <iom...
[no replies]
How come I can not use class initialization to initalize inherited attributes?
 
It keeps saying "Class Troll does not have any field named Health" But, I inherited BaseEnemy within Troll which DOES have a short Health and a short AttackMag...
[5 replies] Last: Hi Frantz. I haven't tried that yet but I don't think that would be th... (by hellohellomoon)
Help please. Keystroke Function?
 
I'm trying to make a function where you have to type press Enter in order for the next display to appear. It looks like this so far. void keystroke() { in...
[9 replies] Last: Oh I see. Thanks whitenite :) (by hellohellomoon)
October 2011 Pages: 1... 2425262728... 59
  Archived months: [sep2011] [nov2011]

This is an archived page. To post a new message, go to the current page.