General C++ Programming - December 2013 (Page 7)

Modifying game lobby
 
I was trying to modify Game Lobby coding so that the output can save the information into a txt file...
[no replies]
solving Quadratic equation.
 
I've seen the example of solving quadratic equation. [a^x^x + b^x +c = 0]. from http://www.cplusplu...
[3 replies] Last: yes. switch(((b^2) - (4 * a * c)) >= 0) { case true: { ... (by IWishIKnew)
Referencing something from a Unique Pointer
 
I'm fairly new to coding c++ and am trying to make a Text based RPG. I've been working at it for awh...
[no replies]
Problem with my program
 
Hi everyone so heres my program the problem is that it only allows me to enter my x and y coordinate...
[1 reply] : It doesn't wait because your not telling it to. You're setting x and y... (by xismn)
Inheritance: Conflict resolution
 
So, say an object has onperator++ what if I want an object that inherits that operator to do so...
[6 replies] Last: alrighty. (by IWishIKnew)
Frazzled by these peculiar pointer behaviors!
 
I have been learning C++ by myself and have made significant progress. I need some insight/help howe...
[5 replies] Last: re: pointer style It isn't a matter of style, it is a matter of what y... (by Duthomhas)
Issue with cout for a char array. Appearance of weird character
 
I used the following code to reverse a char array (string). String itself is reversed but at the end...
[6 replies] Last: Um... In your example, you are having a buffer overflow, which will oc... (by TwilightSpectre)
What's wrong with my code?
 
Hello! This is my first post and I am wondering, what's wrong with the code written below? I get ...
[3 replies] Last: @dawoodr: That's exactly what he meant. To access the first item, you ... (by S G H)
Representing entities with MI
 
I'm trying to make a space shooter and I want to make the code very reusable. So far I've been makin...
[6 replies] Last: Oh, I see! That's a lot clearer. Making the diamond graphics helps too... (by pivottt)
Clearing stringstream
 
Hi, How do I clear a stringstream. I have tried this site and others and have not found anything tha...
[3 replies] Last: #include <iostream> #include <sstream> #include <fstream> std::istri... (by JLBorges)
Vector member functions messing up
 
I am making a game, and I have a vector<string> equippedArmor in class character. One of the member ...
[10 replies] Last: equippedArmor used to be a vector, I then changed it to an array to av... (by TsarLenin)
Can anyone tell what the error because I cannot get the output.
 
Write a program that read from the screen a list of 5 integers values as one dimensional array by us...
[1 reply] : Your code has so many errors to point out individually. If i understan... (by quine)
Nooby question about free
 
Hi , can free function be used without malloc? That is , Student *ptr = stdList->head ; ...
[3 replies] Last: I'm assuming that he's using C since he referenced C functions, and nu... (by closed account N36fSL3A)
my game code requires correction.
 
Game between the two students studying quadratic equation solution. 1.In each round the first stude...
[1 reply] : Please enclose your code in the brackets as shown below. You can do th... (by heyyouyesyouiloveyou)
Reverse of a string
 
Hi, If I am executing following code after reversing it is giving "1" but I need "0001". #incl...
[11 replies] Last: well, I would say you need a for loop: string whatever("Hello World!... (by IWishIKnew)
Whats Wrong with the fraction part
 
#include<iostream> using namespace std; main() { float f; cin>>f; f -= int(f); cout<<f; ...
[5 replies] Last: wikipedia is fairly detailed. float: http://en.wikipedia.org/wiki/Sing... (by Cubbi)
by LeoJet
Help
 
I am writing a program wich read a file of more 3000 lines and it takes many times to read all the f...
[no replies]
Linked List Issues:
 
#ifndef __addressList__ #define __addressList__ #include <iostream> #include <string> using name...
[9 replies] Last: Largin: Thank you very much. Some of your methods look cleaner then mi... (by jocdrew21)
by hassai
sort text file by first number of the line
 
hi can someone help me plz i have a text file like this 0 1 2 C 10 1 2 S 7 1 2 C 11 1 2 S ...
[3 replies] Last: #include <iostream> #include <string> #include <map> #include <fstrea... (by JLBorges)
by adn258
Why Do You Have To Use Different Pointers For Arrays?
 
So when if you want to change the values themselves for example in an array (just for example) this ...
[3 replies] Last: The ampersand & in your case is not the reference operator. int a;... (by Catfish666)
December 2013 Pages: 1... 56789... 37
  Archived months: [nov2013] [jan2014]

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