5,676 Posted Topics

Member Avatar for mybluehair

[QUOTE=mybluehair;1127321]Thanks. also, is there a better way to print out stuff to allegro besides using textout_ex? It seems like textout_ex is going to thoroughly p*ss me off seeing as how specific if you have be to make it work.[/QUOTE] Wrong attitude. It's specific because it needs to be. Once you …

Member Avatar for WaltP
0
135
Member Avatar for truthuntold

[QUOTE=truthuntold;1127429]I am running into problem on getting this program done. Its suppose to quiz you on your 2 powers ie(2^2 = 4, 2^22 = 2m, 2^46 = 32t) I've programmed in python for a couple years but a lot of the tricks python lets us have C++ doesn't or I …

Member Avatar for WaltP
0
100
Member Avatar for emitris
Member Avatar for Cyberhacker

[QUOTE=dusktreader;1127284]First, think about how you would normally create and put numbers into an array. How will you know how big to make the array so that it can hold all the numbers you read in? You should probably dynamically allocate the array with the [B]new[/B] operation. blah blah blah.[/QUOTE] In …

Member Avatar for WaltP
0
125
Member Avatar for jateshs1007

I take it you didn't understand what was mentioned in "[B]Member Rules[/B]" and the sticky post above "[B]Read Me: Read This Before Posting[/B]"

Member Avatar for WaltP
-1
245
Member Avatar for suncica2222
Member Avatar for Narue
0
85
Member Avatar for totalwar235

[QUOTE=totalwar235;1118244]i am having a few errors compiling a code in visual C++ with my jumble word code, can anyone help? [/QUOTE] Yes we can, if you give us an idea what's wrong. We can't see your screen with the errors.

Member Avatar for totalwar235
0
321
Member Avatar for skorm909

Not bad for a first day. One thing you need to learn right away is [url=http://www.gidnetwork.com/b-38.html]this[/url], though.

Member Avatar for skorm909
0
361
Member Avatar for robinotje

[iCODE]strcpy(choice, "yes");[/iCODE] Anywhere you need it initialized. :icon_rolleyes:

Member Avatar for WaltP
0
454
Member Avatar for iamfabian

Oh, c'mon, [B]jonsca[/B] [QUOTE=jonsca;1124220]You will need to either tokenize the lines and get rid of anything after // or between /* */ -or- You can write a finite state machine similar to the ones that a compiler would use... -or- You can use a regex library...[/QUOTE] He said [QUOTE=iamfabian;1124029][B]Totally new …

Member Avatar for tetron
0
404
Member Avatar for Violet_82

[QUOTE=Agni;1124921]OK.. I guess it is the difference of newline characters in windows and unix. I tried on Unix and it worked, forgetting that it may not work in the same way for windows. Probably you can try this [code=c++] cin.ignore ( 80, '\n' ); //reads and discards 80 character or …

Member Avatar for Violet_82
0
139
Member Avatar for hannon565

[QUOTE=jonsca;1126493]It's best [URL="http://www.daniweb.com/forums/post155265-18.html"]not to use EOF[/URL]. [/QUOTE] EOF is fine. It's best not to us [ICODE].eof()[/ICODE] -- a big difference. :icon_wink:

Member Avatar for Nick Evan
0
3K
Member Avatar for nola_Coder
Member Avatar for kevin04

[QUOTE=kevin04;1126210]give me a code to calculate the sum,highest,lowest and average?[/QUOTE] Pretty demanding for a first time poster who can't be bothered to read the Member Rules or any other posting instructions on this site.

Member Avatar for WaltP
0
33
Member Avatar for bobbyross

[QUOTE=xavier666;1094093]Where is this thread heading to?[/QUOTE] Into the Closed Thread heap for too many useless bumps.

Member Avatar for WaltP
0
205
Member Avatar for mikabark

You are attempting to [ICODE]strcat()[/ICODE] to a variable that cannot be added to. What address have you loaded into [ICODE]dir_nm[/ICODE]? That address space is not completely under your control (for example, how large is the space, enough to add characters to?) so you should not be changing it. You need …

Member Avatar for WaltP
0
114
Member Avatar for timbomo

Better. But not quite. Put the tags around the CODE only. Not the entire message. At least a step in the right direction. Now you need to format your code. Indenting is required for people to follow it.

Member Avatar for WaltP
0
157
Member Avatar for mani_singh

That's is not as easy as it sounds... You need to - input the number as a string - test the string making sure only digits were entered - if not, output error - if so, convert the string into your number. I'd wait on this until you learn just …

Member Avatar for Dave Sinkula
0
85
Member Avatar for timbomo

From no Code tags to Code tags every 3 lines. :icon_rolleyes: C'mon, put CODE tags around your code. Don't add them just to add them. Don't add them around questions. Only the code -- all of it. Once -- unless you have two distinct pieces of code (two files, two …

Member Avatar for WaltP
0
85
Member Avatar for sfreema4

[QUOTE=srrid.ajmal;1124469]Try to use fflush(stdin) before reading. It will flush the standard input(keyboard)[/QUOTE] Never, NEVER, [B]NEVER[/B] use [ICODE]fflush(stdin)[/ICODE]. [url=http://www.gidnetwork.com/b-57.html]Here's why[/url].

Member Avatar for tmoorez06
0
209
Member Avatar for gagan gowda

Sure. Stop hijacking old threads. Read the Forum Rule. Check out the Sticky Posts before posting again.

Member Avatar for gagan gowda
-1
84
Member Avatar for nola_Coder

Add a portion of your code in your post -- the part that's giving you trouble -- with CODE Tags (don't ask, they're explained everywhere). And a complete explanation of the problem code helps.

Member Avatar for nola_Coder
0
94
Member Avatar for Kombat

[QUOTE=Kombat;1122359]does this make sense[/QUOTE] No. What happens when you enter [CODE]123 -----[/CODE] [CODE] 123 -----[/CODE]

Member Avatar for Kombat
0
152
Member Avatar for ppotter3

[QUOTE=ppotter3;1124703]I have one error now..... What does this mean? : error C2064: term does not evaluate to a function taking 3 arguments [/QUOTE] Something in your code is specified as a function with 3 arguments, but isn't a function with 3 arguments.

Member Avatar for ppotter3
0
1K
Member Avatar for ssquared

Does your system/compiler actually handle 64 bit values? The 'easiest' way to handle this is to create a union using your double and a byte array. Then output the binary from the bytes.

Member Avatar for ssquared
0
228
Member Avatar for timbomo

I'll give you the benefit of time this time. You received an infraction warning about CODE tags 7 minutes before posting this. Last warning.

Member Avatar for WaltP
0
99
Member Avatar for vipin_98
Member Avatar for cecilia_g1
Member Avatar for Narue
0
138
Member Avatar for cecilia_g1
Member Avatar for cecilia_g1

When talking about integers, they are all stored in [I]binary[/I]. You can display them in decimal, hex, octal, sixbit, etc. but they are all in binary. To see the value in hex, all you need to do is output with the proper format specifier: %X-hex, %d-decimal, etc.

Member Avatar for WaltP
0
76
Member Avatar for icu222much

In order for the functions in the header file to work, you need the [I]code[/I] that is actually behind the function. That code is found in a library file. Look at it this way: The header file is like the phone book. It gives you the people and address of …

Member Avatar for icu222much
0
1K
Member Avatar for invisi

Good. Cuz the answer would've been "[I]Because you wrote it wrong[/I]" Without details, and our lack of psychic ability, what else could we say?

Member Avatar for WaltP
0
306
Member Avatar for OmarOthman

In layman's terms: What precision do you need? If 3 decimals, an EPSILON of .000x or smaller would work. [B]invisi[/B], it is not recommended to compare doubles for equality. The value 25 could be 25.0000001 or 24.9999999. Both are essentially equal, but floating point values are rarely exact.

Member Avatar for WaltP
0
165
Member Avatar for anthony5557

[QUOTE=anthony5557;1124595]Ok, I've figured out how to display the file that the user asks for. But when they enter the wrong file it tells them that there was an error opening the file that they choose. Does anyone know how to make it keep looping the question until they enter the …

Member Avatar for WaltP
0
103
Member Avatar for invisi

If you type in 0 and 0, what are the value of a&b at the end of the while loop? That should help you figure out the two numbers to enter.

Member Avatar for invisi
0
81
Member Avatar for vmanes

[QUOTE=jwenting;1114083]Probably an error in translation :)[/QUOTE] Nope. Translation is fine. It [B]is[/B] gauche. And it's uber-gauche to use [ICODE]goto[/ICODE] :icon_wink:

Member Avatar for ddanbe
1
334
Member Avatar for khaled.s

[QUOTE=khaled.s;1123955]What if i need them to be in the same program, what should i do?[/QUOTE] Figure out what you're trying to accomplish and think carefully about how you can put the code together into one file. It [I]may[/I] mean a [ICODE]if()[/ICODE] statement or two, and another question to the user.

Member Avatar for WaltP
0
239
Member Avatar for angel6969

[QUOTE=Lerner;1123819]in C/C++ the square root of a number can be calculated using the pow() using 0.5 as the second parameter.[/QUOTE] Isn't [ICODE]sqrt()[/ICODE] available?

Member Avatar for jonsca
0
264
Member Avatar for Salem

[QUOTE=apegram;1108445]My password is always the day of the week my password was created. I tell people that, too, because it's not like they'll know what day of the week I created it. That makes it secure. Extremely secure.[/QUOTE] Really? Give me 7 guesses... :icon_rolleyes:

Member Avatar for PedroStephano
0
707
Member Avatar for StaticX

Open another file. If the line is not the one you want, output it. The new file is your result.

Member Avatar for Lerner
0
109
Member Avatar for TeKnoPath

I'd recommend going to a shop that custom builds computers and you can explain what you want and they can match the computer components to you needs. They will also give you good service (generally) -- at least much more than Dell, Gateway, etc.

Member Avatar for WaltP
0
463
Member Avatar for hydersha

[QUOTE=Jeronim;1122882]s/he is using printf with using namespace std it just proves that s/he is beginner in these and s/he need to learn how to think in c/c++ to be able to solve task like these one and s/he wont learn that by reading some text but looking in code.[/QUOTE] [B]Jonsca[/B] …

Member Avatar for jonsca
0
853
Member Avatar for misfits86
Member Avatar for Violet_82

Your class [B]Gradebook[/B] has a private value named [I]courseName[/I]. The only way to put a value in it is to call [iCODE]setCourseName( name )[/iCODE] to load the value [I]name[/I] into it. And since it's a private value you must call [iCODE]getCourseName()[/iCODE] to retrieve it.

Member Avatar for Violet_82
0
148
Member Avatar for sidra 100

[QUOTE=sidra 100;1122965]plz guide me i m having some error at line 28[/QUOTE] After 48 posts you can't give us a better explanation than "[i]some error[/i]." Since you think we're as psychic as you, read my mind for your error. :icon_rolleyes:

Member Avatar for dusktreader
0
130
Member Avatar for kymarscheng

[QUOTE=kymarscheng;1120927]How to store the data of a program without using registry? Because I don't want the users change the registry and the program settings... Are there any other ways that can prevent the users from changing the settings?[/QUOTE] Don't open the registry? What makes you think you need to store …

Member Avatar for kymarscheng
0
166
Member Avatar for mmasny
Member Avatar for Salem
0
100
Member Avatar for cybergirl

So start a new thread and ask a proper question. Check out [url=http://www.daniweb.com/techtalkforums/faq.php?faq=daniweb_policies]the Rules[/url]

Member Avatar for codename09
0
1K
Member Avatar for esesili

[QUOTE=esesili;1122371]Hi All, When I try to compile the code below, I get error message " error: ‘MAX_IMG_HEIGHT’ undeclared here (not in a function)". [/QUOTE] Where is [ICODE]MAX_IMG_HEIGHT[/ICODE] defined? What's its value?

Member Avatar for dusktreader
0
93
Member Avatar for MJaske
Member Avatar for MJaske
0
199

The End.