Beginners - October 2012 (Page 31)

by sch518
Can't quite figure this out
 
I have to read in a line and get this output: in: convert 2-9 out: 29- in: quit I can't get the program to quit when 'quit' is typed in because I am usi...
[3 replies] Last: try getline (by Aramil of Elixia)
Help on a project
 
So my class has this project and I am just not sure where I should start. Here is the project. I would just like hints on where to start. Thanks Note: The __ in...
[6 replies] Last: Okay, so I finished my code and it works I was hoping someone could lo... (by OLittleO)
New and needing help to pass class
 
Hey everyone. I'm in a C++ class that I'm currently failing. The teacher doesn't believe in helping her students because she believes they will figure out how t...
[4 replies] Last: On the right of the reply box, the button with <> will add code tags t... (by maeriden)
Quite new at C++ and needs help
 
Ok so I've been trying to make this simple bank program but I cant figure out one bit the problem is that it'll always end up $20. #include <iostream> #incl...
[6 replies] Last: Oh Thanks Alot Guys :) (by epicssy)
need clarification plz
 
x=8 if(x==8) cout<<"welcome"; else cout<<"go back"; cout<<"home"; the output for this code is welcomehome but i am wondering why is not just ...
[9 replies] Last: yeah it starts at one and its less than 10 so it prints it and then ..... (by Aramil of Elixia)
Why do I have this problem?
 
Here is the code for my program: #include <stdio.h> #include <conio.h> int main(void) { int num1; int num2; printf("Enter 2 numbers"); ...
[2 replies] Last: To be exact, 32 bit signed ints have a range from -2,147,483,648 - 2,1... (by Moeljbcp)
need help asap please
 
my code compiles but I get error : "FATAL ERROR - CAN NOT OPEN FILE shoppers.dat" // --------------------------------------------------------------------...
[5 replies] Last: Well, I'm using a MinGW shell but I can compile and execute just fine ... (by maeriden)
Number of vectors in a vector of vectors?
 
I have a 2d vector that is not necessarily square. I want to know how many rows and columns it has (obviously, it isn't really 2d, but I'm thinking of it as an ...
[4 replies] Last: Went with what I said in the OP and everything worked out, thanks all ... (by georgep)
by jc4bs
Confused by Deleting Repeating Characters in an Arrary
 
I have a partially filled array consisting of the following ten type char variables: a = 'a'; a = 'd'; a = 'g'; a = 'f'; a = 'a'; a = 'd'; a = 'x'; a =...
[1 reply] : Something like %unique(List, Result) unique( , ). %an empty list doe... (by ne555)
by rm214
Longest code I've worked on.
 
Hello, I'm a first time poster and new to c++. The code that I am working on is from my programming class. I am not looking for anyone to fix it but I do need...
[2 replies] Last: Thanks Brent for your help. I will take another look tonight and let ... (by rm214)
by ummer
faces of dice
 
I am learning programming language first time, need help with compile the program. Using the random number generation, I need to get the out put like this: ...
[2 replies] Last: This line is incorrect: for(i = 1; 1<=40; i++) (a) you have 1<=40 ... (by Chervil)
by nexos
NEED HELP
 
i need to do this program and i am stuck .....so if someone who knows how to do it plz take 5 minutes and help me , i would be really grateful for u help . ...
[8 replies] Last: i fixed it ........ here is the resoult , try it and tell me if i can ... (by nexos)
by Djeed
Read data file into 2d array
 
Hi there, As a newbie, I could barely ever find any clear information on how to read a text file (made of space- or tab-separated numbers in columns) and sto...
[2 replies] Last: Thank you for your thoughts, Fransje. I'll update the #defines with 'c... (by Djeed)
by jacek
reference to pointer
 
reference to pointer: int func(char *&ptr) { if (something()) { ptr = new char ; return 10; } else { ptr = new char ...
[1 reply] : I think this will work, so long as you remember to delete ptr out in ... (by Zhuge)
How Do I Use Header File???
 
I've been trying to do some research about header files but I still not understand most of them. I've only known that we have to use a header file for linking p...
[5 replies] Last: You should probably post another topic, but post a link in here if you... (by strongdrink)
by Ch1156
How to find all instances of a word in a string (1,2)
 
I have a program and im trying to find all instances of a word that the user typed in. but it just stops working when it gets to the while statement. #inc...
[24 replies] Last: Oh i see, what about .str(); ? i read that it converts an integer valu... (by Ch1156)
a question about rational class
 
hi, I wrote this code about sum,subtraction,divided,multiple of fraction numbers.but when I enter 4 numbers it shows only number 2011 .plz tell me where is pro...
[8 replies] Last: I provided a quick fix to a problem. You don't need a constructor, bu... (by Lowest0ne)
test
 
this is just a test to see if I remember how to post code on this forum!! private: class BinNode { public: DataType data; ...
[1 reply] : you have [\code] (by Ch1156)
help
 
Write a C++ program that reads in three floating point numbers from the keyboard and the finds the arithmetic, harmonic and geometric mean. how to do this?
[5 replies] Last: ok ,thx (by Joseph544310)
by jacek
std::equal
 
1. std::vector<unsigned char> vec; vec.resize(5, 0x61); std::string str = "aa"; if (std::equal(vec.begin(), vec.end(), str.begin())) { ... String is s...
[4 replies] Last: Yes it is ok. In this example it is unimportant that you can compare u... (by vlad from moscow)
October 2012 Pages: 1... 2930313233... 84
  Archived months: [sep2012] [nov2012]

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