Beginners - March 2011 (Page 36)

Using String class to output a word
 
We learned about object oriented programming. The assignment was to make two classes and have it output specific data. The first class -- Box -- works fine. I'm...
[3 replies] Last: I have to ask, if you can use std::string, why even make this class? I... (by Zhuge)
by Cecc
Partitioning with a Pivot
 
Hey everyone, I'm trying to write a program that has an array with 10 elements. It takes in a Pivot from the user and then gives the output: elements lower...
[1 reply] : Lines 16,28 are out of bounds. (by ne555)
variable change not recorded
 
hi, i'll cut to the chase :D #include<stdio.h> double AAA=1, BBB=2 ; void app(double a, double b) { a = a +100 ; b = b + 10 ; } int main (voi...
[1 reply] : app needs to take references if you want AAA and BBB to be modified by... (by jsmith)
runtime error Vectors
 
Im trying to compile a source that seems correct however, i get a runtime error any ideas? Though, i did comment out the display and it ran but nothing ran so i...
[2 replies] Last: I fixed it thanks :) MagicSquare::MagicSquare(int n) { size=n... (by danielwow)
by amaac
Error String does Not name a Type
 
Hello I have a project that needs an input parser. I keep getting an error and cannot find the problem. it has been a while since i wrote in C++ and i am not e...
[6 replies] Last: something important is not to put any imported code #include "any.h" b... (by jpaulino05)
Need To interview someone please ;(
 
For my chemistry class, i have to pick a profession and describe how chemistry is involved in it. I chose to do the field of computer science. All i would need ...
[2 replies] Last: Ok great :) just email me and ill send you a list of questions you can... (by paki programmer)
How do create codes for a payroll Report?
 
Hi, I am taking a C++ course and is stuck on one the questions on my homework assignment. How do I make the output look like this: Employee Hourly ...
[4 replies] Last: ok, thank you! This should help (by shrill223)
Any1 pls help!! memory allocation issue
 
char letter; string astring; cout<<"Enter a string: "; cin>>astring; // vector<char>word; char *word = new char [astring.size()]; cout<<siz...
[4 replies] Last: Thank you so much Quirk and Framework!!!Very helpful.But.. (Below is t... (by alex58765)
Problem with Strings
 
I am trying to write a program that takes sms phrases like brb or lol and replaces them with the proper terms like be right back or laugh out loud. I am having...
[16 replies] Last: Re your code: I must have missed that when I looked through all the ma... (by mikeofthenight)
Homework regarding functions.
 
Hey all... I have a homework assignment and I am stumped. Here is the assignment: The following formula gives the distance between 2 points x1,x2 and y1,y2...
[14 replies] Last: I have noticed that the pow() sometimes chokes when fed integer argume... (by closed account D80DSL3A)
Why Can't VS 2010 Debugger Show a 'static const' class data member?
 
C++ Gurus, I'm in the process of learning C++, and make every effort to use the Visual Studio 2010 debugger to aid in that process. Right now, I'm explorin...
[4 replies] Last: Thanks again, jsmith. It's good that there are smart (and experienced... (by DGolfer)
Dynamic Cast
 
Hi All, So If i have a class A and i derive another class B from A. now in a fn . i have input as A* Now this code. void fn (A* a) { if (A* a...
[7 replies] Last: If D1 and D2 are both derived directly from B, then a crosscast is a c... (by jsmith)
by Budlee
Class issue Urgent help
 
Hi, I have a class that I'm pretty sure should compile but could be a bad instalation not sure. THis is the following code if some one could compile it wo...
[2 replies] Last: You forgot a ';' at the end of 'class addsub' (by coder777)
Glitch with site
 
Hi guys I had no idea where to place this so thought I would post it in the topic I found it at. I was recently looking through some posts and on one post w...
[2 replies] Last: ah I see. Thank you for the link. (by Chazzmundo)
Writing game saves to a file
 
With file streaming and writing, how can I read on the a specific section and then alter it? E.G.: file .................. Last player position "100100 ...
[1 reply] : well how about the following: Imagine your save data is always saved ... (by Chazzmundo)
initialization lists
 
i have searched many sources about initialization lists but i can't find a useful source . can't understand what it is and for what it is used .Can Anybody exp...
[5 replies] Last: An initialization list can also be referring to initializing elements ... (by closed account S6k9GNh0)
How can i do this?
 
I want to make multi typedef app. Such as this: #include <iostream> #include <typeinfo> using namespace std; int main(){ typedef char,int,string,float,double ...
[16 replies] Last: @Hanst: std::string uses the '+' operator for concatenation. Additiona... (by Moschops)
by Geric
Need some ideas // projects ,problems to workon
 
GUys, Im a newbie here , can you give me some problems. to solve that can help me practice
[14 replies] Last: T T yah .. @albatross -- i`m aware of that , not that affected righ... (by Geric)
Console (display window) stops working after entering a value.
 
Good day, people! I'm working on a homework/project on C++ on conversion of decimal (base-10) values to hexadecimal values. Right now, I have this code: ...
[4 replies] Last: You're welcome. Glad you got it working. (by closed account D80DSL3A)
Average of lines that start with certain letter.
 
I need a little help getting the average of only specific lines in a file. The file looks like this. Day 2 23:06:26 2.937039 -64.9 -65.5 -66.9 2 ...
[13 replies] Last: Do not ask me.lol I have a hard time understanding the way he "teaches... (by smr0930)
March 2011 Pages: 1... 3435363738... 52
  Archived months: [feb2011] [apr2011]

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