Beginners - February 2010 (Page 2)

Char Pointer Array Compiler specific
 
This really simple program is giving weired results it compiles without any errors and runs properly if i don't declare c (which is not used in program anywher...
[2 replies] Last: Well, you are right it is abusing pointers and the result is bound to ... (by Brother)
by michy
getting address
 
hello, currently, im doing an Overflow attack. im having a problem of c and c++ coding. i have a c coding to get memory address like: char buf printf("M...
[13 replies] Last: HAHAHAHAHAHHA Oh... my... God. I can't believe I didn't see th... (by Disch)
pointer problem
 
can anybody help me make a program that does this: the program asks the user to enter an address(referring to integer address). The address is stored in a te...
[2 replies] Last: i think you are searching for something like the following: http://cpl... (by Incubbus)
opening a file
 
My problem is I try to call outGameFile.open("GameData.txt"); only I replace "GameData.txt" with a variable that equals it. string file; file = "GameD...
[2 replies] Last: oh wow thank you! string getfile = User.getFile(); outGameFile.ope... (by xyriene)
array and point
 
Well basically i copied a program on youtube but the problem is i wont work. We are using different compilers. here are my codes: __________________________...
[3 replies] Last: i solved the problem by adding this printf("Address of x: %p \n", *... (by baphomet90)
output problem with cout <<
 
when I compile this program: #include <cstdlib> #include <iostream> #include <limits> #include <string> #include "math.h" using namespace std; doubl...
[12 replies] Last: you say the code outputs the solutions are... but your cout says c... (by gcampton)
Detect a character in my calculator program?
 
I've made a calculator program which calculates the desired calculation(including accumulation(+), subtraction(-), multiplication(x) and division(/). But I have...
[1 reply] : http://www.cplusplus.com/forum/articles/6046/ (by bluezor)
by so3ad
Prime Factoriztion
 
I have a problem writing a program that will input from the user any natural number greater than 1 , and outputs all the prime factors of that number , in the f...
[1 reply] : I wrote one a while back. I will say two words...modulus operator. (by Seraphimsan)
by EEVIAC
trouble displaying floating-point value
 
Hi. This program is suppose to accept your height in inches, and convert it to FEET with the remaining inches displayed also.... [CODE:] #include <iost...
[7 replies] Last: Got it working : ) Here is the new code: #include <iostre... (by EEVIAC)
using a function to move a pointer(I think :| ).
 
Hi folks I think this is my first post so please let extend my greetings and salutations. and now of course I'd like a little help. :P I'm trying to get ...
[4 replies] Last: Hello again. Thank you for the replies! I have managed to get this ... (by crinkelite)
Exiting a do while loop
 
I need to exit the 2nd loop after it meets the else if statement .. but how do i do that without having to enter q to exit? I will soon have to enter the conver...
[4 replies] Last: cout << "\nEnter the highest gallon value to display <q to quit>: ";... (by foobarbaz)
passing char[][] by reference (1,2)
 
I keep getting errors trying to pass a dual array of char by reference. void foo(char& **arr) { } void foo(char& arr ) { } Neither of the above se...
[22 replies] Last: Thanks mate. (by gcampton)
Colorkeyed Images
 
Using the SDL_Image library, I am using a colorkey with some images, but whenever I resize the image, or change it's file type, many of the border pixels are ra...
[1 reply] : If I'm not misstaken, turning off the smoothness when you're resizing ... (by Warnis)
Removing Characters with boost::regex
 
I need to search a file with boost regex and remove what is found. I will not always remove what is found sometimes I will replace so I was trying to us regex_r...
[6 replies] Last: Line 56, shouldn't that be: std::string new_string = boost::regex_... (by PanGalactic)
Manipulators
 
Hi guys, do you know some doc about c++ manipulators? Or anyway what does manipulators mean? Where to use it etc. ? Thx for help. EDIT: In order to avoid mi...
[3 replies] Last: Yes, you can write your own manipulators. Manipulators that take no a... (by guestgulkan)
asking user for output filename
 
I'm having some trouble with getting my program to display an error message when the user enters an incorrect filename. It just skips over the loop I put in for...
[4 replies] Last: Problem solved! Turns out the "garbage" filenames I was inputting were... (by jojojlj)
using Switch statement
 
am trying to solve this: Write a switch statement on the (nonnegative integer) marks m so that it outputs _ 'H' when m≥85 _ 'D' when 75≤m<85 _ 'C' when ...
[9 replies] Last: case ‘m>=85’: marks = "H"; switch; m>=85 does not work in s... (by amit0991)
hey
 
im new on this site and im taking c++ for video game design and the assignment we're working on a program that asks you how many fav. games you have and what ...
[7 replies] Last: Well I am sorry. (by vection)
prevent user to input non-number in int, float...
 
so in those math programs we need the user to input some numbers, right? but the problem is when he makes a mistake and puts a non-number into an int or float....
[4 replies] Last: u can either call a function for wrong input and display the msg to in... (by amit0991)
can any1 tell me why im getting this error
 
Error 1 error LNK2019: unresolved external symbol "void __cdecl output(int)" (?output@@YAXH@Z) referenced in function _main RPG.obj RPG test
[1 reply] : You made a function prototype for void output(int); and you called t... (by Disch)
February 2010 Pages: 1234... 32
  Archived months: [jan2010] [mar2010]

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