Beginners - January 2013 (Page 29)

read whole lines from cin into vector
 
Hey, here is a small problem i have a little trouble solving myself and finding hints or tipps for on the interwebs: I want to use copy() from the STL to ge...
[6 replies] Last: I want to use copy() from the STL to get input from cin directly to a... (by Cubbi)
Can you help me to find my errors?
 
I was tasked with making a tictactoe game that takes a string of inputs and then generates the board and the state of the game. B's are blanks and then the regu...
[2 replies] Last: thanks man. the "&&" worked perfectly (by byronflds)
Hours have been spent!
 
I don't care how easy the answer is to this. Why, when the word input has been initialized does it say it hasn't been. Is it out of scope or something else? ...
[5 replies] Last: Perhaps its the meaning of the word "initialized" which needs clarific... (by Chervil)
Questions about vector::resize
 
I'm trying to initialize a private vector in a constructor. When I call resize before I push_back on the vector, I get a bunch of 0s when I call GameBoard::pr...
[5 replies] Last: No problem pal (or at least no problem from me), That's what the forum... (by TheBeardedQuack)
how do i encycrpt a mobile phone number
 
the number is a contact number,For privacy reasons this has to be encrypted by printing the next ASCII character for each number. useing loops for this.
[2 replies] Last: This type of simple encryption is known as a type of "rolling code" be... (by TheBeardedQuack)
Ultra basic Link List trouble
 
I am trying to remember how to build a basic linked list, it has been a while since my data structures course. I feel like im pretty close with this code, bu...
[3 replies] Last: You could declare the function as void addToHead(Node ** head); and... (by vlad from moscow)
Coding style/layout - easy to read?
 
Just wondering if anyone could comment on the layout of my code and how it is written. Obviously I'm still very much learning about the language and programming...
[1 reply] : It works! But, the new file isnt formatted properly. For example: ... (by closed account 18hRX9L8)
ld: library not found for -lcrt0.o
 
I am trying to compile a program package for my computer called DSSP. It requires the boost library. I have boost on my computer and it should be working fine. ...
[5 replies] Last: I didn't ignore them, I tried to recreate my problems as I went throug... (by vckngs7)
!!!problem-Reading from a file
 
Hi everybody!I am a beginner in C++ and I can`t find a solution for this problem.I`ve written a program that calculates the points of sportmen in competition fr...
[no replies]
Vector Problems. Needing assistance
 
I am using the following code. to try and build a vector, and then send that vector back to my main. void VectorGrab(vector<double> VF) { vector<double>...
[7 replies] Last: I believe this is because the vector FinalList has no size, That is... (by jlb)
If/else question
 
This is a homework question... I have completed it and worked out everything but this: I am a nested if to determine the smallest number. If the numbers a...
[7 replies] Last: only problem is that nesting stuff can get hard to understand after a... (by Chervil)
need help to cast from array of floats to void* ?
 
Hi I need help with casting issues i have function that gets some void* data and i try to send it float** array but its write an error "error: cannot conv...
[1 reply] : try something like: float *foo=static_cast< float* >(voidPointer); ... (by fafner)
by erdc
comparison between pointer and integer problem
 
With thhe following bit of code I always get the error of: ISO C++ forbids comparison between pointer and integer ////////////////////////////////////////////...
[2 replies] Last: Oh, it is an array. Now I understand. My code now does compile. Thank ... (by erdc)
Stumped by what this means
 
I have been asked to write a program(in C++) which, given three values representing the sides of a triangle prints: 0 if the values cannot be the sides of any ...
[4 replies] Last: Oh now I see. thanks for the clarification (by bunyonb)
A few beginner questions
 
Hi everyone, This is my first post on these forums, so if I do anything wrong, tell me, and I will watch it in the future. My questions are: (1) How can...
[2 replies] Last: Thanks for the fast reply :) My game is a 3D game, which uses a Game ... (by Jstylezz)
by rey9
inserting sorted linked list
 
i am making a program that inserts data in a sorted linked list(in increasing order) this is my code: #include <iostream> using namespace std; class No...
[2 replies] Last: Hi there, Consider this function: [code firstline=50]void sortedInse... (by closed account o3hC5Di1)
Problem with reading a single character.
 
#include <iostream> #include <cstring> #include <iomanip> using namespace std; int size=0; int get(char b ); int set(char b , char c ); int main() { cout<<"E...
[3 replies] Last: Thank you dreamincolor and MiiNiPa for you help. Now I'm having anothe... (by Sahil512)
Lists of vectors, ideas
 
Hi, all! One naive question: How can I save a different number of two-dimensional vectors in one element for an example is it a good idea to save them in ...
[1 reply] : you could save them in another vector, that would make it threedimensi... (by Darkmaster)
I'm having problems with my code
 
Sorry guys, i'm an absolute newbie and need help with this code. I'm trying to get the program to shutdown the computer once a numeral password has been enter...
[4 replies] Last: Thanks guys(Gals). The code works like a charm! I've learnt how to han... (by Maximum)
Extreme newbie help
 
I don't understand why this doesn't work. Actually I understand it somewhat because the compiler told me "invalid operands of types "double" and "int" to bina...
[3 replies] Last: Thank you all math-genious, programmitous superhero men! (by gaggerzon)
January 2013 Pages: 1... 2728293031... 52
  Archived months: [dec2012] [feb2013]

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