Beginners - November 2011 (Page 61)

help me find the error, and solve it!!! ASAP!!!!!!!!!!!
 
#include <iostream> #include <cmath> # define PI 3.14159 using namespace std; void getRadius(double ); void volSphere(double, double & ); void volHemi...
[4 replies] Last: I am not to sure but in the declaration of void volHemisphere(double... (by TheMassiveChipmunk)
I could use some help! (1,2)
 
Hey guys, ive been learning c++ in the past few days and I want to make a simple program. You input a password if its correct, then you get to do an addition, i...
[22 replies] Last: I think i get it now Edit: Thanks so much guys, i learned a ton :D th... (by cheesynacho)
Array's + Pointer's = ???
 
im confused on this. #include <iostream> using namespace std; int main() { char *c,c1 ; c = &c1 ; cin >> c1 ; cout << c1 ,"\...
[2 replies] Last: No, no, no! That snippet does this: char * c; char c1 ; Anyway, th... (by moorecm)
Please help!!!
 
trying to use a function to calculate average grade and ive fallen off the tracks.... #include<iostream> using namespace std; void findAverage(int &, int ...
[1 reply] : http://www.cplusplus.com/forum/beginner/54038/ Please refrain from ... (by ciphermagi)
by AdumUp
In Need of Assistance
 
I have been having a problem with my IDE lately. I am using the latest version of Code::Blocks. When I try to build I am greeted with a wonderfully red list of ...
[15 replies] Last: Have you tried going to Windoze Add/Remove Program Wizard and removing... (by ciphermagi)
How to print out the time?
 
I have a program that works great, but the only thing that would make it work even better would be if, say, every minute, it printed out the time. Right now ...
[3 replies] Last: C works in C++ if you include the correct header files. (by ciphermagi)
In Need of Assistance Please
 
Hi i have to write a code that allows the user to key in any number of item prices for items purchased in a discount store. Display the grand total amount of al...
[14 replies] Last: okay never mind this is just confusing me even more, thank you for tr... (by ctrygirl)
Trouble with output
 
Hey all, I'm writing a program that finds the root mean square of a series of numbers the user inputs. When the user wants to exit the program they wi...
[5 replies] Last: Then do this: if(root == 0) { cout << "No data" << endl; } e... (by ciphermagi)
Why use char for cin.getline()?
 
I'm new to c++ and came across this in one of the examples: char filename ; char input_line ; cout << "Enter a file name and press ENTER: "; ...
[2 replies] Last: In fact, it's preferable to use std::strings when taking input, as the... (by helios)
by gh24
Sorting An Array
 
Hi Guys, I have an array of unknown size. I need to sort the vector (can be smallest to largest or largest to smallest) BUT I need to keep the index of the arr...
[11 replies] Last: Yea the initial idea I had was correct, I was just trying to sort it a... (by gh24)
array not deleting
 
void f(int * & a) { int * temp; temp = new int ; temp = 2; temp = 20; a = temp; delete temp; } int main () { int * v ...
[8 replies] Last: void f(int &a ) (by ciphermagi)
by CIS
Mad lib
 
I have another problem, I have to rewrite Mad Lib Game, so that no strig objects are passed to the function that tells the story. Instead, the function should a...
[2 replies] Last: Thank you!.... (by CIS)
Sorting the marks and the Students names together...
 
How to sort them together. I want to sort students marks in ascending order but also would like to sort the names which is array of strings in my program. Pleas...
[10 replies] Last: ok thank you i will try to imply it (by biplav17)
using function for MPH
 
Im new to functions and im not sure why I cant get this to run?? any help would be greatly appreciated! :) #include<iostream> using namespace std; void f(i...
[3 replies] Last: I figured it out, Thank you! (by kcomp11)
by rucafe
dynamic allocating array
 
I am dynamically allocating a 3D array like so float* Array = new float[height*width*depth]; I need to dynamically the 3D array because it is very big (...
[4 replies] Last: You could make a wrapper for the 1D array value_type& matrix3d::oper... (by ne555)
void functions
 
Hey guys I'm new here. I have a little bit of knowledge about c++ but I need some help with this problem. I know my program doesn't work, but if you could help ...
[3 replies] Last: no it not better. For starters now you have an erroneous while statem... (by markyrocks)
ofstream question
 
i have a main.cpp, function.cpp and a header.h , i want to use ofstream to send message to a txt. messages are located in the functions on the function.cpp. Whe...
[12 replies] Last: no i took out both from main.cpp (by imgregduh)
by chekz
Files Question
 
Hey guys looking for some help. I have a text file. In this file there is a single function." printf("Hello World"); " What I want to do is to read the fu...
[2 replies] Last: I could do that and that would make sense. But I am looking to do it m... (by chekz)
Putting the answer of a equation into command in
 
I am teaching myself C++, the problem I have to answer is In Mathematics, the quantity of b^2-4ac is called the "discriminate." Write a program that asks the ...
[7 replies] Last: I'm pretty sure Mathhead knows why you were using a system call. It's... (by cnoeval)
by Tsax
Loops
 
Hi, I am trying to write a loop but only have my variable increment every other time through the loop. I know to have it increment every time it would be someth...
[1 reply] : Well, you could have for( int x = 2, t = 1; x<10; t = 1-t, x+=t )... ... (by hamsterman)
November 2011 Pages: 1... 5960616263... 65
  Archived months: [oct2011] [dec2011]

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