Beginners - May 2012 (Page 14)

Vague Struct
 
hi... I have piece of c++ code that I didn't get it. It's just a struct. Is there anyone could help me to understand this code. here's my code: struct...
[6 replies] Last: yeah..sure could you please answer my 3 questions and after that intro... (by Blackwizard)
calculation using multiple components
 
Hi, I'm having some problems with some code I'm editing, its made up of about 200 components (nightmare). I've managed to read around a bit and get some idea of...
[2 replies] Last: Thanks- problem solved! (by hyplobates)
Logic behind path finding... Sort of
 
Ok so I'm in the process of developing a 2D tower defense. There will be a set path for the enemies to travel on, though I'm not sure on how to go about impleme...
[7 replies] Last: Yes. You can catch that, though. When the user tries to build a towe... (by Disch)
An interesting question
 
Hi,everybody: several days ago,I meet a problem. Here is the description: A truck want to cross a desert , the length of this desert is 1000 km. The tru...
[8 replies] Last: I have an idea~~~~ #include<stdio.h> typedef struct GasStation { ... (by zhouhaibing089)
How to re-assign a vector with some constants ?
 
Hi all, I have a vector declared somewhere : vector<int> v(2); I want to change its values. v = {4, 5}; does not work, nor v = vector<int>({4, 5}); Is ...
[no replies]
sscanf fails with %ud
 
I have basically this code : char someVar = "11.1.0"; unsigned int m_Index; int bit1,bit0; sscanf(someVar,"%ud.%d.%d",&m_Index,&bit1,&bit0); Wit...
[3 replies] Last: You could also use strtoul ( http://www.cplusplus.com/reference/clibra... (by S G H)
Is this considered defining the variable
 
Can i consider n to be declared already when the function bool prime is being declared as shown below??? #include<iostream> #include <cmath> using na...
[7 replies] Last: Thanks i understand it now. (by qawsed51)
math operators
 
im starting to learn c++ and i have to make a program with a little math , but also have to give the answer to the math problem written and i'm not sure if it g...
[2 replies] Last: but i was not sure if it was right or wrong to remove the parentheses... (by Kronolynx)
Using member functions in another classes
 
I'm doing a small messaging program right now and I decided to try and make my code more solid by dividing it up into classes for each task etc. That way I don'...
[3 replies] Last: I'm still quite curious about how function methods can talk to each o... (by Moschops)
by Rii
[C++] 4D Multimap
 
Hello there, I'm Rii ^o^ I'm trying to read a .csv file into a 4D multimap in C++(using Visual Studio 2010), but I'm stuck at entering data into that multimap,...
[15 replies] Last: There's no point in rounding for this problem, as you said. I'm not e... (by Gaminic)
by bn1462
how to edit data in a file
 
last bit i need to finish a project is how to edit or update data in a file. is there any other way apart from reading all the data and rewriting into a new fil...
[2 replies] Last: is there any other way apart from reading all the data and rewriting ... (by cire)
File I/O - Binary structure
 
I'm getting into c++ after having done a bunch of Java / PHP programming. I'm writing a budgeting program that has things like: pages (month of data), various m...
[1 reply] : http://www.parashift.com/c++-faq-lite/serialization.html (by cire)
Rotation in tetris game?
 
I am making a tetris game in c++ and darkGDK and need help on rotation. Here is my current code: Here is one way I tought about doing rotation but need mo...
[1 reply] : void Shape::rot(int x , int y) { int xp, yp; xp=x-y+y; yp=x+y-x; ... (by cire)
by brk
mod
 
Hi everyone, I need to take mod of two double numbers by using % command, When I am trying to take mod of 18%5, the result is 3, OK. But when I am tr...
[2 replies] Last: Thanks a lot for your help Brk (by brk)
█ Need Help #2
 
Hello, i'm a serious newbie in c++ & i have been given to Print table of 5 in proper format ( 5 * 1 = 5) . I'm not asking for the solution i wanted to just as...
[1 reply] : What compiler are you using (before I rip your code to shreds ... in a... (by closed account 1vRz3TCk)
by Unknow
Wondering
 
Hi I'd like to know something. I'm 14 years old and I want to take a c++ course. But, I have no knowledge about any other scripting languages (except a little...
[2 replies] Last: Hi there, I'm just learning C++ myself, coming from a scripting (PHP)... (by closed account o3hC5Di1)
Do-While loops
 
It's me again and I need your help! I'am currently having difficulties with this problem, create a program that will ask the user to enter a character and that ...
[5 replies] Last: ΗΕΥ,mine is working with string like you want,so why not help it? (by skarla)
by Landu
Assist needed for assignment
 
I have an assignment in C++ and I suck at it so much that i got low grades in my mid-term exams and the last chance of passing is through an assignment which I ...
[3 replies] Last: Hi, Another tip to get you started would be to code the project incre... (by closed account o3hC5Di1)
by devoid
try for read file
 
sorry, my english is not good hi, guys.. sorry... i have problem... #include <fstream> #include <iostream> #include <stdio.h> #include <conio.h> #in...
[1 reply] : Hi, Can you tell us a bit more on the problem please? What's the pro... (by closed account o3hC5Di1)
Syntax Question for index in a loop
 
I believe there is something similar to: if (counter++ && value1 < value2) { //do something } and I was wondering if anyone knows what it might ...
[1 reply] : http://www.cplusplus.com/doc/tutorial/control/ (by R0mai)
May 2012 Pages: 1... 1213141516... 59
  Archived months: [apr2012] [jun2012]

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