Beginners - September 2008 (Page 3)

about reading integers in a string
 
Hello, this is my first post here. I want to ask how to read multiple integers in a string using atoi for example int main() { int a, b, c; string...
[3 replies] Last: Oh, I made it. Thanks. (by leguminous)
Slot machine c++ code question
 
hhhh
[1 reply] : Your switch() only executes if choice is 1. What you want to do is ... (by jsmith)
Getting an output while running a program without using \n
 
Hello, I was wondering if anyone could help me with a quick problem. I'm trying to run a program that takes a lot of time for computations. I've been want...
[6 replies] Last: Awesome!! That worked perfectly. Thanks! (by aeson25)
by taklct
number change to words
 
i need to create a program that will convert numbers into words... example input: 1 output: one 50 inputs... but need to use switch and cannot use if/e...
[4 replies] Last: take a look at where you can re-use switch statements you've already c... (by jpeg)
displaying numbers properly/comparing character input
 
Hello. I have two problems. One is that I cannot get my numbers to display properly. If you run the program with certain values that should clearly average a...
[4 replies] Last: Hmmm.. tried switching everything to a double but that didn't work for... (by acevans2)
by taklct
c++ switch problem
 
#include <iostream> using namespace std; int main() { int number; cout << "Please enter a number <1-50>:"; cin >> number; ...
[3 replies] Last: thanks you for your answer i know what i'm wrong now^^ (by taklct)
Strings..?
 
How do you get a string to white space without messing up? I am trying to type in "Annette's Kitchen" for a food program and it shoots my whole program down >.>
[1 reply] : C++ getline http://www.cplusplus.com/reference/string/getline.html ... (by jpeg)
by jyzap
Calendar Program
 
HI everyone..i'm new here..please help me in my project..a calendar program from year 2008 - 2010..please help me...ASAP..tnx..
[12 replies] Last: geeezz! thats my project too! but its a calendar from 1901 to 2008! ... (by kwncy)
If (argv[1] != argv[1]) { Why(); } //?
 
Visual C++ 2008 Express Edition #include <iostream> #include <fstream> using namespace std; int main(int argc, char* argv ) { if (argv == "-c") ...
[1 reply] : http://www.cplusplus.com/reference/clibrary/cstring/strcmp.html (by helios)
Can anyone do this or even make this?
 
Help for making this kinda "colourbot" if i move my mouse over a red or blue object in the game than the "bot" must grab that object and if the object moves,...
[1 reply] : No one is going to do your work for you, you should take a look at the... (by Umz)
output being saved into a separate file
 
Hi folks, Im taking a C++ class and the assignment is to make a program that calculates sales tax and then saves it to a text doc that can be viewed later. I...
[1 reply] : Try splitting up the program into functions so that main has less to d... (by Umz)
Trouble Using C++ Program
 
Hello! Thank you for taking the time. ^_^ I have Microsoft Visual C++ 2008 Express Edition and I attempted to use it as a regular C++ compiler, but that doe...
[7 replies] Last: I use VC++ and to get a "blank" project you need to select a Win32 Con... (by eker676)
read "white spaces"
 
hi, i write this code: #include <iostream> using namespace std; int main(){ cout.unsetf(ios::skipws); cin.unsetf(ios::skipws); char name ;...
[2 replies] Last: ok, thanks, its work ;) (by ijk5tra)
by Vector
Atoi with String varaible
 
Hi, im trying to use these while condtion to read my file. hile ( getline ( inFile, sLine ) ) { if ( sLine.length()...
[3 replies] Last: sLine has the contents of the file. What i did in C Syntax is used ... (by Vector)
Trouble with a Do While loop
 
//Dan Masella Calculating the most cost efficient phone payment plan for the customer #include<iostream> #include<iomanip> #include<stdlib.h> using names...
[10 replies] Last: Worked it out, and got everything to work. Thank you very much everybo... (by UconnDan)
Pointer assigned to correct memory location not working
 
Hi, first of all, the code: RPC<uint32> local_catalog_address = remote_qp.get_local_catalog(); cout << "local_catalog_address: " << local_catalog_addre...
[3 replies] Last: Vencenzo, please do not post to multiple forums. The thread is also a... (by jsmith)
by Evote
Quick Question Adding Strings and Floating point.
 
My question is simple. how do i make this work. All the variables are floating point. And lineNum is mealy a number to assign the variable in a array. I do ...
[1 reply] : Your code isn't much better with all the extraneous parens. What is... (by jsmith)
iterator to access STL list
 
Hello, I have some problems to access the list by iterator accordingly. 1. The list 'mylist_' and struct 'i' have to be redefined in a class file. Should...
[1 reply] : Please post your original code. There are many grammatical errors in ... (by jsmith)
by main
struct in struct
 
class Calculator { private : static int com_num; static int digit_num; struct command { string name,comd...
[1 reply] : There isn't enough information to be able to answer either question. (by jsmith)
by Kidd87
linked list problem
 
my text file looks something like this 1234 jack hammer 75.00 .45 10 5678 Daffy Drill 25.00 .67 10 9887 Flash light 30.00 .87 10 When I open up my text ...
[1 reply] : Please do not post in multiple forums. I answered your question here:... (by jsmith)
September 2008 Pages: 12345... 16
  Archived months: [aug2008] [oct2008]

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