Beginners - March 2014 (Page 41)

Code Executing Even When Conditions Aren't Satisfied?
 
In the program I'm writing, I begin it by getting two pieces of input (both are type "double") using cout and cin statements. If the first double is < 0 OR the ...
[3 replies] Last: Do not enter random strings? Check for failure status after each input... (by MiiNiPaa)
by Legato
Explain Loop Invariants to me
 
Hi, I'm on a section in my book that talk about loop invariants, apparently are statements that you would write before a "while" statement to make sure the "...
[no replies]
Classes, arrays
 
Hello im trying to find some help. im trying to build a text based game as my first game and I have a class called Room to hold my information (ex room#, Descr...
[1 reply] : Room arr ; — c-style array. std::vector<Room> arr(100); — C++ ... (by MiiNiPaa)
by enemy
array of objects
 
Hello! We have a class: product and 3 objects: toy, book and dress. How can we reach objects as elements of an array? Many thanks! #include<iostream> using...
[6 replies] Last: lhs is a parameter name just like in any function. lhs is short for le... (by MiiNiPaa)
by enemy
Save as in eclipse
 
hello! I have problems with saving in eclipse. problem is that I cannot OPEN the document I saved. It asks u for a path, and I have it. I find the doc in that ...
[no replies]
Whats better? typedef or using
 
I was wondering what is the better of the two type alias the using name = type or typedef type name . Like are there advantages in any?...
[3 replies] Last: Thank you guys, so I should use the using, because its C++11 (by closed account EwCjE3v7)
Battleship program -- Structs and Arrays
 
My friend and I are working on a battleship program. We want to use a player struct and two variables (player one, player two) so that we can use the same funct...
[3 replies] Last: Great, thanks! It does just what I need it to now :) (by altenhos)
Using Graphs
 
My assignment says: 2 miners are trapped in a mine after an avalanche. Fortunately they have found a passage to get out. That passage is too small for both of t...
[2 replies] Last: http://stackoverflow.com/questions/19193413/pathfinding-in-a-grid-syst... (by MiiNiPaa)
by dcradu
OOP problem
 
I have to do a library system using OOP . I have a class "entry" which has some data like title, year etc. and 2 derived classes, one "book" that has author and...
[5 replies] Last: I'm sorry if you read my deleted post, without any context it took me ... (by Computergeek01)
by AOU17
Junk Mail Program Help
 
Hey guys, I have this programming assignment and I'm stuck, I'm asking for some help because I don't know what I'm doing. I just need someone to point me in th...
[no replies]
I have just established Turbo C++ and..
 
I have problem with the quotation mark key (""). Does anyone knows how can I activate it ? (or the keyboard combination to activate it ?
[6 replies] Last: thanks !! (by dapontes)
sfml code error
 
I am trying to run a program that uses sfml and I keep getting this error: "error while loading shared libraries: libsfml-window.so.2: cannot open shared objec...
[no replies]
Please
 
Display8=-1 means Anybody can explain
[2 replies] Last: it means display = display * (-1); (by MiiNiPaa)
Queue
 
Please explain the following Node*temp; temp=New node; temp->Next=NULL; rear->NEXT=temp; rear=temp;
[2 replies] Last: Why do you ask? Is it your homework to work out the logic of a code sa... (by keskiverto)
erase vowels from list<string>
 
I have to write a function that seeks for vowels inside list of strings. After vowel is found it needs to be erased from list. After all vowels are erased list...
[5 replies] Last: You need nested loops. One to iterate over list, other to iterato over... (by MiiNiPaa)
public member friend class – error cannot be overloaded
 
Dear everybody, I want to define a friend class using this code: 1 #include <iostream> 2 using namespace std; 3 4 class substraction_class; 5 6...
[1 reply] : public: substraction_class (int parameter1) : c(parameter1) {} ... (by MiiNiPaa)
syntax error : missing ';' before '<<'
 
I am using Visual Studio 2013. Error in structure... syntax error : missing ';' before '<<' unexpected token(s) preceding ';' #include "stdafx.h" #...
[1 reply] : Never seen a struct written the way you have done it. Take this entire... (by Smac89)
Displaying date of birth
 
I am making a program that asks the user for their date of birth ,and then displays their approximate age using "2014-year=age" .the second part of code is work...
[5 replies] Last: Fixed the bug ;; the original code is now #include<stdio.h> #includ... (by Ahmed50)
ITERATIVE PERMUTATION
 
I hope this code helps someone with iterative permutation (it is not simple),but with basic source-code and use only one basic library, this permutation only wo...
[9 replies] Last: Long time ago, I was bored. So I decided to do what you did, except I ... (by Smac89)
floating pointer format not linked
 
i try to do stuct using pointer tat include float. how to fix the error of "floating pointer format not linked"? #include<stdio.h> #include<conio.h>...
[1 reply] : IDK what line the error occured on yours, my compiler doesn't report ... (by nvrmnd)
March 2014 Pages: 1... 3940414243... 79
  Archived months: [feb2014] [apr2014]

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