Beginners - November 2014 (Page 53)

Class errors
 
Hi guys. Im getting started with my program and am getting error on my set up of the classes. Not sure why i think im doing them right. line 13, 17, 21 say cont...
[4 replies] Last: Line 24: This is a zero sized array. Not allowed. (by AbstractionAnon)
Help with 2 array function
 
Hi all, Would you please help me with this code. Just mention this code is not still complete and I will add more. Until here in this code. I defined particles ...
[4 replies] Last: You say that the code is not complete and that you will add more. How... (by keskiverto)
by Mido14
Array of Objects
 
How to pass and return an array of objects?!
[1 reply] : http://www.cplusplus.com/doc/tutorial/arrays/ (by keskiverto)
template could not be deduced
 
I am writing a program where I read text file and input the lines into arrays. After that I have to find largest value in each array. I am using template and I...
[5 replies] Last: Oh I re-edited the post Thing is you shouldn't change the return type... (by closed account SECMoG1T)
Tic tac toe outputting weird characters
 
I'm the millionth person to do this, but I'm making a tic tac toe game (currently unfinished) and have been using a class to store the board information about t...
[3 replies] Last: I've run into another problem. My class Boardstatus is not behaving co... (by UnclePutin)
Linked list within a class
 
Is this a possibility? I want a class that was certain values and a linked list in that class. The class should look something like this: class C { publi...
[3 replies] Last: You'll need a class with the data you wanna list then the class List..... (by dualdark)
Hangman Project
 
Hello! I am pretty new with the C++ language and programming all together and I am having difficulty with this hangman project I am working on. The program sho...
[1 reply] : Found the fix myself.... After taking a break and coming back to it ha... (by vcaropr1)
Why an lvalue is considered an expression ?
 
I'm using the book Programming -- Principles and Practice Using C++ by Bjarne Stroustrup and I'm having some difficulty with the definition of expression. Her...
[6 replies] Last: An assigment returns a reference to the object that is being assigned ... (by Peter87)
Copying an array and then reversing the numbers
 
Good morning everyone. I am working on a program that will let the user input 10 numbers into an array then copy that array and hopefully output the copied arra...
[2 replies] Last: Thanks coder777!! I did not know I was that close to having it done! (by guglaak)
What is the code for the following?
 
1. Create three source files (asgn6.h, casgn6.cpp and asgn6Driver.cpp), an object file (asgn6.o) and an executable (asgn6Driver) in your bin directory on Li...
[6 replies] Last: Thanks (by suko123)
Taking in a series of orders with a loop, and then outputting the final order total
 
Hi, I just made an account here after searching on the web for a bit for an answer. I have a c++ programming assignment that takes in information from the us...
[3 replies] Last: Nearly. just replace your line 3 with my line 8. i.e. don't use the va... (by mutexe)
Problem. Bubble sort in a linked list.
 
I have this code, and crash when i try to sort void ListaServicios::OrdenarBurbuja(){ curr=first; bool sort=true; for(; sort; ) { sort=fals...
[1 reply] : Where are curr and first declared and defined? You could be dereferen... (by AndyMc)
Quiz Averages
 
I am having trouble in including the class average and the individual averages. This is what I have so far. Any help would be appreciated. [#include <iostrea...
[2 replies] Last: Remove: double average = (quiz1+quiz2+quiz3+quiz4)/4; and befor... (by AndyMc)
Unintialized local variable? what
 
It says the variable in my class member FindTotal is unitialized local variable #include <iostream> #include <ctime> using namespace std; class ...
[2 replies] Last: Initialise tots to zero before using it: int FindTotal() { int ... (by AndyMc)
No errors, but no output, why?
 
I have this code that runs smoothly ( no errors) but there is no output. Every time I run it. It says "build succeeded" and that's it. I must be missing somethi...
[3 replies] Last: What happened to the code? (by Zhuge)
Get the vector element index
 
Hello, i'm trying to get a vector element index in a vector of string, but i get weird results. Could someone explain the best and the fastest method to use? ...
[6 replies] Last: Find my error: i was using a wrong vector with similar name. Shame o... (by Amiplus)
Why won't my program display the contents in the array properly?
 
I've made a program that will ask the user to input information about their account savings. But i'm having some trouble trying to display the contents properly...
[1 reply] : You do ignore() each first character, don't you? (by keskiverto)
by girl
Formatting output
 
Hey, I want to output numbers llike this: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 etc I write such code: int i=0; int j = 0; for (i = 1; i <= n; i++) { for...
[4 replies] Last: Yeah, it works. Thanks guys :) (by girl)
by Akigou
For Loops(Random variables)
 
I made a for loop and I was hoping that it'd make the D variable I put in the paranthesis for ( ) a random number each time How do I make it so I can get a ra...
[3 replies] Last: That's because your loop adds all numbers from 1- 1000 to dataused . ... (by YokoTsuno)
infile/outfile
 
anyone know why my file just terminates. #include <iostream> #include <fstream> #include <iomanip> #include <string> using namespace std; int main() { ...
[10 replies] Last: im glad i got it to run im behind 1 lab so i did this one because were... (by poseidn)
November 2014 Pages: 1... 5152535455... 65
  Archived months: [oct2014] [dec2014]

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