Beginners - September 2012 (Page 17)

by skarla
help
 
I have made a half snake game. The only thing that i have not put is that when the snake eat to grow up. So you know how to do this?(console game). If yes ...
[6 replies] Last: Sorry? What exactly wanna say? Anyway is anyone interesting to help me... (by skarla)
divide and conquer
 
in the algorithms of divide and conquer, it is shown that the function works simultaneously like the following way: 8 4 ...
[7 replies] Last: I don't think I understand the method here. If you are trying to find ... (by georgep)
by bugz
Help !
 
Hello how do you write a program using a link list for a particular stack that will store data of the type char. Calling a member function named pushing to pus...
[3 replies] Last: first of all, when you post code, please enclose it in code tags. Cli... (by doug4)
Printing '$' and ',' with Output
 
Hello! So i think I've worked out all the details of my program except for this one last one... Can you guys help me with printing a '$' and ',' sign with my...
[8 replies] Last: @whitenite1 not a problem at all, thank you sir! (by ilovelearning)
Various questions....
 
Working on a program for a class assignment and I've ran across a few questions that I was curious about and haven't been able to find answers to. I have taken...
[1 reply] : 1-Handing user input is one of the most difficult things in programmin... (by soranz)
Breadth-first search program taking too long
 
I'm working on question 3a from the British Informatics Olympiad 2012: http://www.olympiad.org.uk/papers/2012/bio/round_one.html A number can be transformed ...
[no replies]
How do I display 2 decimal points after a value?
 
Our professor wants us to display 2 decimal points even if they're both 0. For example if my answer is 1435, it needs to be 1435.00. How Do I go about doing thi...
[1 reply] : Maybe the setprecision manipulator in <iomanip> would be of intere... (by Albatross)
Converting Char * to Const Char[]
 
Hi, I am new to C++ coding. I am trying to convert Char * to Const Char but I am not able to do it. Here is the snippet bool Method (Char *location) ...
[6 replies] Last: You may not use c_str() as an argument for a parameter of type char *.... (by vlad from moscow)
Movie Seating Problem
 
Hey all. I have been going crazy these past few days trying to figure out this seating assignment problem and was wondering if someone could help me. Instruc...
[no replies]
g++ compilation problems
 
I have a simple program with three files: programa.cc (contains the main function), pilha.cc and pilha.h (that describe a the class Pilha, that simulates a stac...
[4 replies] Last: Exact! Thank you Peter. Worked perfect, the problem was on the compila... (by guerreiro)
by manudo
If error
 
Noob programmer here, so be patient please. :) So, I tried everything for this program to work, the code can explain by himself but if in case that it can't ...
[2 replies] Last: Thanks, it worked, but now the program doesn't return any message. (by manudo)
Overloading Operators for Derived Classes
 
I have an assignment to derive a Runner class from a Period class. A Period consists of hours(int), minutes(int), and seconds(float) and is in the format of hh:...
[3 replies] Last: So it turns out that when I copied and pasted the main.cpp from the .d... (by Brett Stott)
Error: no operator "==" matches these operands
 
I'm trying to perform a binary search on a vector of strings, and I keep getting this error. The entire program is rather long, so I'll only post the part that...
[2 replies] Last: I don't think so...here's the class declaration for PhoneEntry (if tha... (by taymaxi)
ex 6 cable cannot call function correctly
 
hi i cannot seem to call the function printBill() correctly for processBill(). I had to use a switch statement to call printBill() but it says too few arguments...
[5 replies] Last: thank you ! (by andrewddo)
Curly Brackets (1,2)
 
If I write this program in two different ways - one without the brackets, and one with, would it function differently? Like for A, do both if statements have ...
[25 replies] Last: Oh I see, just making the else attached to the first if. Thanks (by cheshirecat)
by khal
make
 
Hi, I was wondering how to create a Makefile that will run in terminal with just typing test (without having to type ./test)? all: g++ test.cpp -o te...
[3 replies] Last: What? Look, a makefile solely exists to build the program. It has NOTH... (by Athar)
complexity of bineary search
 
we know that complexity of binary search= O(logn) because going from n to n/2 to n/4 to 1 takes logn steps actually, i was trying to calculate it from a dif...
[4 replies] Last: ya..got it..thnx (by vgoel38)
How to subtract 0.5 from this random
 
How do I make it randomize a -0.5 in addition to the 0.5? In other words how do I make it randomize so the output is sometimes 1.5, 2.0, 2.5, 1.5, 2.0 when I en...
[2 replies] Last: you're the man (by skittlesaddictx50v)
by RipIt
Input through Text Box
 
Am i able to make text box's through which the user can enter information into and have that information saved? Using either regular C++, SFML, or some other wa...
[4 replies] Last: For widgets, yes. But probably not for widgets on an SFML rendered wi... (by Disch)
by Joe101
const question re: switch statement
 
Can anyone explain why 'case y' below, throws the error : 'y cannot appear in a constant expression' . { int x =3; const int y = x; int z = 5; switch...
[2 replies] Last: So if you changed 'x', 'y' would be trying to change to what 'x' is b... (by Peter87)
September 2012 Pages: 1... 1516171819... 62
  Archived months: [aug2012] [oct2012]

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