1,362 Posted Topics

Member Avatar for rtmarch

What mrboolf said is correct, you're displaying the address of the costs array. Also, put line 91 before the output in line 89 - you are not storing the computed cost to the cost array till after display. The [icode]<<fixed<<showpoint<<setprecision(2)[/icode] are sticky settings, they don't need to be in the …

Member Avatar for vmanes
0
118
Member Avatar for The Dude

Mmmmmmm, beer! Here's some [URL="http://thinkexist.com/quotations/beer/"]quotations [/URL]about the wonderful brew.

Member Avatar for vmanes
0
91
Member Avatar for avpy

I think the problem here is you need to also define copy constructor and operator= methods. Since you are allocating pointers in the constructor, the system provide shallow copy is not sufficient. When c has been assigned the result from temp, at destruction time temp has been destroyed, and thus …

Member Avatar for vmanes
0
122
Member Avatar for bcurt85
Member Avatar for Nick Evan
Member Avatar for Obeledeveloper
5
358
Member Avatar for vmanes

[URL="http://gizmodo.com/5090397/10-gadgets-that-have-no-business-using-a-jet-engine"]What to do with too much time and money?[/URL]

Member Avatar for Jen0608
0
81
Member Avatar for vmanes

[URL="http://www.youtube.com/watch?v=P5_Msrdg3Hk"]Funny movie[/URL]. There's a moral to the story.

Member Avatar for The Dude
0
82
Member Avatar for PhoenixInsilico

In the malfunctioning sample, you have parameter names for the get function the same as the class's members. In the function, the parameters are in local scope, so the [icode]x=x+2;[/icode] is only referencing the parameter passed in. Thus, you are adding 2 to the uninitialized value of main's X. How …

Member Avatar for PhoenixInsilico
0
789
Member Avatar for The Dude

I had an inkling at first, from the rhythm. But wasn't sure till later on.

Member Avatar for Jen0608
1
69
Member Avatar for Ancient Dragon

Keyboard vid - been there ,done that. Got the key imprints in fist to prove it ;) Treadmill - wonder if there's someone with a remote control hooked up to it? That would be a wicked prank.

Member Avatar for Jen0608
0
81
Member Avatar for dise652
Member Avatar for cout<<"alias"

[code]while (x || y != 00) ;[/code] You cannot compare in that fashion and get the result you want. What your statement says is [icode] while ( x OR y ) not equal to 0[/icode] which compares the boolean result of ORing x and y, comparing that result to 0. …

Member Avatar for cout<<"alias"
0
386
Member Avatar for BioHazard90

The [URL="http://sdmines.sdsmt.edu/cgi-bin/global/a_bus_card.cgi?SiteID=228101"]average starting salary for recent undergrad CS majors[/URL] from my university is $56K.

Member Avatar for vmanes
0
183
Member Avatar for joeblob17

The problem is paramter "p" to the function. Since it's passed by reference, and if you don't reset it (as I assume you don't want to), it comes back into the function at a value greater than 0. Actually, it will be 4 with the data you show. When you …

Member Avatar for joeblob17
0
87
Member Avatar for cog_bn

I agree with WaltP - the for( ; ; ) is really less clear your intent than while(true) - if you think that's too long, then while( 1 ). Really, how often do you really mean to have a loop be infinite? When you see either of those constructs, that …

Member Avatar for cog_bn
0
184
Member Avatar for vmanes

When I first saw a book on the shelf, in the computer section of the bookstore ,with this title, I was confused. Really, why would they have picked that TLA for Project Management Professionals? It's just begging for jokes. Does a PMP drive around in a big convertible Cadillac with …

0
59
Member Avatar for mastr924

Your prompt to enter a row should be just inside the outer (m) loop, since that loop controls rows. Also, normal style for for loops is to compare counter < limit, rather than your convoluted counter <= limit-1. Why is your inner loop a while, instead of also being a …

Member Avatar for Lerner
0
111
Member Avatar for The Dude

That's handy, as neither Google translate nor Babelfish do British to American - which are nearly different languages.

Member Avatar for jbennet
0
76
Member Avatar for Undermine

Before you can shuffle the deck, you need to assign values to it. Maybe something like: [code] int i; for( i = 0; i < 52; i++ ) deck[i] = i+1; //assuming you want values 1-52 [/code] Now that you have some values, shuffling makes sense.

Member Avatar for StuXYZ
0
593
Member Avatar for MJFiggs

If you're referring to your array Items, then you've got to use the strcpy( ) function to copy from one index (a row of your 2D array) to another. This line [code] if ((choice != 1) && (choice != 2) && (choice != 3) && (choice != 4) && (choice …

Member Avatar for MJFiggs
0
121
Member Avatar for chunalt787

I find that it compiles fine, after you take the excess [icode][numberOfNodes[/icode]. I would think that removing the const keyword from your parameter list would clear the error you're getting. FYI, you're not declaring or allocating a 2D array. [icode]bool* matrix;[/icode] will be a 1D array only. (using VC++ 2005)

Member Avatar for chunalt787
0
303
Member Avatar for Tex_Waco_USMC
Member Avatar for vmanes
0
87
Member Avatar for sting23
Member Avatar for vmanes

[URL="http://www.youtube.com/watch?v=q96n_nnDhxU"]Ad for Lenovo[/URL] (Disclaimer - not responsible for whatever you actually do.)

Member Avatar for jbennet
0
69
Member Avatar for inssanity21

First, do you know how to code a sort? You could read your textbook or look [URL="http://tinyurl.com/6jh368"]here[/URL] Once you can sort one array, simply modify the function to take both the names and numbers arrays. Sort based on names - every time you move two names about, make the same …

Member Avatar for vmanes
0
94
Member Avatar for Se7Olutionyg

[QUOTE=Se7Olutionyg;743100]help help please[/QUOTE] Please please stop making new threads for same subject.

Member Avatar for vmanes
0
337
Member Avatar for dtaylor01

The first two are because you have local variables in main( ) with the same names as your functions - the compiler looks to the nearest defined name (the int's), which are not functions. What are these lines supposed to be doing? [code] while (depth == 0); [/code] [code] END …

Member Avatar for vmanes
0
109
Member Avatar for Se7Olutionyg

This [code]while (solution != blank) { //play game until the 'blank' puzzle becomes the 'right' answer [/code] is not going to work. You cannot directly compare the strings this way. Look up use of strcmp( ) function. Your guess checking block seems to be flawed [code] //check guess! int State …

Member Avatar for vmanes
0
327
Member Avatar for M^2
Member Avatar for cam875

sin( ) and cos( ) take angles in radians, not degrees. Take your degree angle and multiply by (PI/180). Note that you will find a very good value of PI in the cmath library - check what you need to access it with your compiler.

Member Avatar for cam875
0
99
Member Avatar for The Dude

What a hoot! Makes about as much sense as some other belief systems.

Member Avatar for jbennet
0
57
Member Avatar for vmanes

[url]http://images.google.com/hosted/life[/url] [quote]Search millions of photographs from the LIFE photo archive, stretching from the 1750s to today. Most were never published and are now available for the first time through the joint work of LIFE and Google.[/quote] Wow, google is good - photos going back to the [b]1750s![/b] That's about 70 …

Member Avatar for GrimJack
0
63
Member Avatar for Fanch

Try posting in the appropriate Software Development forum. Present more specific details of what you want to accomplish. Take a stab at it and post your code, ask questions about it. Read the sticky posts and announcements in the forum you choose, so you follow the accepted process there.

Member Avatar for Stefano Mtangoo
0
92
Member Avatar for Alex Edwards
Member Avatar for maxicube
Member Avatar for maxicube
0
154
Member Avatar for SoprtsFilmer

[b]RTFM - Read The Full Message[/b] They tell you where the problem is and what it is. Even if you don't fully understand the messages, they're pointing you to the problems. Look closely.

Member Avatar for vmanes
0
362
Member Avatar for Lardmeister
Member Avatar for Troulsofs

Not quite as grand a victory, but setting up a power adapter for my wife's dollhouse jukebox. She got a [URL="http://www.hallmark.com/webapp/wcs/stores/servlet/ProductDisplay?catalogId=10051&storeId=10001&partNumber=QXG7244_DK&rank=P1R2S&searchValue=song&fromSearch=true"]Hallmark Christmas decoration that's a jukebox [/URL](it plays about 4 different Christmas songs and flashes lights) that's meant to plug into a string of lights on the tree. She wants …

Member Avatar for jbennet
0
130
Member Avatar for vmanes

"At roughly 4:30 p.m. Eastern time last Tuesday, the volume of junk e-mail arriving at inboxes around the world suddenly plummeted by at least 65 percent, an unprecedented drop caused by what is believed to be a single, simple act. " Read the rest [URL="http://www.washingtonpost.com/wp-dyn/content/article/2008/11/18/AR2008111801120.html?nav=rss_technology"]here [/URL]- quite eye opening.

Member Avatar for jbennet
0
164
Member Avatar for CMacDady

What is your problem with [icode] result[i] = Customer(f,s,bal);[/icode] What does Customer( ) return?

Member Avatar for CMacDady
0
145
Member Avatar for The Dude

[URL="http://www.streamdrag.com"]Here's another good one[/URL] for finding music, plays music and videos from youtube.

Member Avatar for Ezzaral
0
89
Member Avatar for charlesh901

from the results of googling this problem, bad keyboard or keyboard cable seem likely. If you want to try repairing/replacing components, here's a good link on how to open it up: [url]http://www.uofr.net/~greg/hardware/hp_pavilion_n5430_disassembly.html[/url] Val

Member Avatar for steve.q
0
375
Member Avatar for tpluscomb

For starters, the partition function seems to be missing a lot of array indexes

Member Avatar for ArkM
0
921
Member Avatar for laki234
Member Avatar for Quendy

Which compiler are you using? VC++ Express versions don't have the MFC or ATL components.

Member Avatar for vmanes
0
557
Member Avatar for scamguru

Hmm, write a little program that will read the file and store it, properly formatted as a declaration of a string with that content as the initialization, saving as a .h file to be included in your program? Run that prior to compiling the primary application.

Member Avatar for vmanes
0
109
Member Avatar for NewGuyCPP

And also pay attention to where the error message points you. It should include the line number of the code where the compiler believes the problem is. This will at least focus your attention to the right place. Beware that sometimes the actual problem is a line or two or …

Member Avatar for cikara21
0
118
Member Avatar for kotkata

No, cin >> does not take in the newline. Your problem is the processing loop [code] for (int i = 0; i <= strlen(code.c_str()); i++) [/code] Running your loop to <= string length means you are processing the NULL terminator at the end of the string. Loops for handling strings …

Member Avatar for kotkata
0
94
Member Avatar for Niner710
Member Avatar for Black Magic

You mean something like [URL="http://www.daileyint.com/build/buildtoc.htm"]this[/URL]?

Member Avatar for caperjack
0
108

The End.