Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

0 Endorsements
~680 People Reached
Favorite Forums
Favorite Tags
c++ x 5
Member Avatar for bobanderson93

i have a text file "test.txt" with "This is a secret file" in it. I want to read in the whole sentence in with white spaces and manipulate each character. How can i do this? My current method leaves out white spaces. [CODE]const int SIZE = 17; char string2[SIZE]; ifstream …

Member Avatar for Ancient Dragon
0
107
Member Avatar for bobanderson93

something is wrong with my dequeue function. When i try to output the value that's about to get deleted i get garbage on the console window. the enqueue function works fine. [CODE]class Queue { private: int value; Queue *next; public: void dequeue(); void enqueue (int num); }; Queue *head=NULL; void …

Member Avatar for Karkalash
0
175
Member Avatar for bobanderson93

every time i run the program it prints out 0. I think something is wrong with my display function but i cant see the problem. [CODE]#include <iostream> using namespace std; #define STACKSIZE 10 class stack { private: int arr[STACKSIZE+1]; int tos; public: stack(); void push(int x); int pop(); bool is_empty(); …

Member Avatar for richieking
0
131
Member Avatar for bobanderson93

so i have a char array that can hold up to 1000 items.. but it might not be filled up completely. How can i prevent the program from printing garbage on the screen after printing the real values from the array. btw i am reading from a file, sorting by …

Member Avatar for WaltP
0
115
Member Avatar for bobanderson93

the program wont compile because it found and error with ReadFromFile class method in the main.cpp file. Any help would be appreciated. class inventory deceleration in "Inventory.h" file [CODE]#ifndef INVENTORYDEF #define INVENTORYDEF #include <iostream> #include <fstream> int const MAXNAME=30; int const SIZE=2; class Inventory { private: int quantity[SIZE]; float unitcost[SIZE]; …

Member Avatar for Ancient Dragon
0
152