5,237 Posted Topics

Member Avatar for jcps65

First, unwind that excessive indentation. 12 closing } in a row is just awful. This is how you should do an if / else if / else chain [code] if ( cond ) { } else if ( cond ) { } else if ( cond ) { } else …

Member Avatar for Salem
0
96
Member Avatar for Rmitboy

> char filename[] = ""; This has no space to store an input - instant buffer overflow and broken program. Also, consider using fgets() to read each line, then deal with the line in memory.

Member Avatar for Salem
0
156
Member Avatar for rizzi143

Have a go at working out an answer, and post your reasoning here. Then we can tell you if your approach is good. Simply telling you the answer won't help you understand why it is (now), or help you in a similar circumstance later.

Member Avatar for Salem
0
295
Member Avatar for tsy123

The "problem" is that it is still pseudo-code. > if (ch is an operand) This needs to be turned into real code.

Member Avatar for Salem
0
149
Member Avatar for guri1509

Try using a search engine. <spoon> [url]http://ark.intel.com/Product.aspx?id=47663[/url] [url]http://ark.intel.com/Product.aspx?id=43537[/url] </feed>

Member Avatar for guri1509
0
32
Member Avatar for vishy1618

> I hope this is the right place to ask such questions. The Qt forums might be better. Forums such as this typically deal with language issues. When you're deep into some specific oddity of an API, then it's best to check the forums / other support for that API.

Member Avatar for vishy1618
0
115
Member Avatar for vbx_wx

> ftp = InternetConnect(internet , "127.0.0.1" Why are you trying to upload it to yourself?

Member Avatar for vbx_wx
0
157
Member Avatar for martinjcloud

[url]http://www.daniweb.com/forums/announcement118-2.html[/url] Post an attempt, then we can work out what to tell you to help you learn.

Member Avatar for Salem
0
48
Member Avatar for gregarion

Since you're using C++, then[ICODE] std::vector< std::string > lines;[/ICODE] would save you from knowing in advance how many lines there are. Look up the push_back method for vector.

Member Avatar for jonsca
0
91
Member Avatar for dr_michali

> x=(float**) malloc (T*sizeof(float*)); 1. Make sure you're compiling your code with a C compiler (not a C++ compiler). If you're getting warnings about "void* to T*", then you're compiling C++ code. 2. Remove the cast of the return result. It does nothing useful if this really is C code. …

Member Avatar for dr_michali
0
232
Member Avatar for coool_iq
Member Avatar for MVB
Member Avatar for jeffdude87

s/urgent/yawning [url]http://www.daniweb.com/forums/announcement14-2.html[/url] Try a career in management if all you can think of doing is passing the work on to someone else to do.

Member Avatar for Salem
0
102
Member Avatar for prushik

If you want to see what's happening, then do [ICODE]gcc -v -o hello hello.c[/ICODE] It will print out the full command lines generated for the compiler, assembler and linker. If you really wanted to, you could do the same things yourself. But doing so is highly specific to your current …

Member Avatar for Banfa
0
202
Member Avatar for johndoe444

> I was looking for c++ specific i/o. But there is no *man* page for it like cin/cout. If it isn't cin/cout (or more generally, the C++ streams), then it's nothing to do with C++. For such information, you need to read the additional documentation which comes with your compiler …

Member Avatar for Ancient Dragon
0
173
Member Avatar for KMW12345

Well perhaps if you posted YOUR implementation, we might be able to tell you what's going wrong. Or start single stepping the code through the debugger, rather than relying on other people to debug your programs for you.

Member Avatar for jephthah
0
660
Member Avatar for Whusmaname

The short answer is yes. The longer answer is no. > I'm not a student of the computer languages Without some ability to write out the commands you want to perform, it's going to be hard to explain at a distance. > (when no-one's available to set it manually.) Does …

Member Avatar for Whusmaname
0
302
Member Avatar for marinkapell1
Member Avatar for serious01

> read from an application program like Microsoft excel Do you mean this? Or do you mean read from "excel format" .xls files, and print that? [url]http://www.microsoft.com/interop/docs/officebinaryformats.mspx[/url] Get ready for a long reading session.

Member Avatar for serious01
1
133
Member Avatar for mduncan8

What exactly does port.read() do? Things I can think of include - it doesn't append a \0, so all your string functions are working on a prayer. - it doesn't do "framing", so if you happen to lose sync with the transmitter, you end up with messages like this > …

Member Avatar for mduncan8
0
160
Member Avatar for XerX
Member Avatar for sam_dev

> base64 algorithm which is used for the encryption of passwords No it isn't. Base64 is just about turning the unprintable into the printable. The data from any 3 random bytes is converted into 4 printable characters. Reversing this (back to 3 bytes) is easy. Then the real challenge begins.

Member Avatar for jephthah
0
123
Member Avatar for crodriguez08

> gradeavg[0] = gradetotal[0]/i; I see here you're doing integer division, so you will get truncated answers. If your grade scores are not integers to begin with, then your data types for reading the file are wrong. An example file format would help

Member Avatar for Salem
0
134
Member Avatar for mommie

> It compile but it keeps giving me 0 which is not correct. For what values of n and k? > denominator = denominator *i ; These would have numeric overflow pretty quickly. Add some debug to print each denominator value in the loop. Also show us how you print …

Member Avatar for VernonDozier
0
100
Member Avatar for sklingb1

Well that depends on what kind of array you have. [url]http://en.wikipedia.org/wiki/RAID[/url]

Member Avatar for sklingb1
0
109
Member Avatar for gunnarflax

Why not design your images locally in 32-bit mode, then convert them to some other format for publishing. There are a number of different image formats, which allow you to trade quality for size. Pick the one which fits your needs.

Member Avatar for gunnarflax
0
124
Member Avatar for Zafrusteria

> For Multi-line comments the lines must be removed not just space filled as it looks way to ugly! And a file full of #line directives isn't ugly? Seriously, is anyone going to READ your post-processed code? Do it in several steps - replace each comment character with a space …

Member Avatar for Salem
0
380
Member Avatar for ItecKid

Read the documentation for your C compiler. The normal C convention is to pass all arguments on the stack.

Member Avatar for Salem
0
62
Member Avatar for laehc

The cache works better when you HAVE loops, not when you don't. If all you've got is straight-line code, then the very fast processor is essentially bypassing the cache and it is stuck waiting for slow memory to deliver the next instruction. A populated cache on the other hand can …

Member Avatar for laehc
0
149
Member Avatar for Darkest Shine

Use %1s if you want to read a single letter (and make the result char aLetter[2]). %c takes the next character without exception.

Member Avatar for Salem
0
130
Member Avatar for needHelpVBA

What does gender or geography have to do with your question? [url]http://www.catb.org/~esr/faqs/smart-questions.html#bespecific[/url] > I have to do a very imporant project. Important to who? [url]http://www.catb.org/~esr/faqs/smart-questions.html#urgent[/url] > I have read a book, but just from reading and following those instructions I am not able to key my own tool But if …

Member Avatar for needHelpVBA
0
94
Member Avatar for Alexia Ooi

You have one massive function to do everything. Break your list steps into - initialise list - append to list - print list - destroy list

Member Avatar for Salem
0
149
Member Avatar for TheWolverine

How does your program exit? One of the requirements for getting a gmon.out file is performing a "normal exit", which basically means dropping off the end of main() in the usual manner. If your program just drops dead, then you're not going to get a profile. Practice with some simple …

Member Avatar for TheWolverine
0
2K
Member Avatar for tonyrockcakes

port (for example) is just a local variable inside the function. If you want it to be visible anywhere else, then it needs to be a class member variable.

Member Avatar for tonyrockcakes
0
231
Member Avatar for lighten123

[url]http://cboard.cprogramming.com/cplusplus-programming/125034-access-dynamic-path-folder-ios-ofstream.html[/url]

Member Avatar for Salem
0
96
Member Avatar for johnir

[url]http://clusty.com/search?query=hp+bios+password+reset&sourceid=Mozilla-search[/url]

Member Avatar for johnir
0
146
Member Avatar for bobbuilder67

Because one thing (directx) has nothing to do with the other (eclipse). If you're having problems with directx, then you should be reading directx manuals and tutorials, and trying the example code. Finding a new IDE won't fix that at all.

Member Avatar for Salem
0
170
Member Avatar for sandyjain

> while(!feof(file)) This doesn't do what you think it does. feof() only becomes true when some file reading function (say fscanf has already FAILED). But since you don't check that, you potentially end up with some junk on the last record. Consider this an alternative [code] while( i < 100 …

Member Avatar for Banfa
0
161
Member Avatar for tcsarindam

> file.read((char *)&s2,sizeof(s2)); Well scribbling all over the base of your object in the hope that it will land on your class private members is way too much to hope for. You need to arrange proper access to this memory.

Member Avatar for Salem
-1
88
Member Avatar for theonlywalks

There was a burst of I/O activity here as well. [url]http://cboard.cprogramming.com/c-programming/124972-when-implementing-cpu-fcfs-algorithm-what-does-process-do-after-i-o-burst.html[/url]

Member Avatar for Salem
0
134
Member Avatar for Chris_Giarla

The approach is good, but take smaller steps. So instead of [code] while ( *p ) { char c = *p; if ( c >= 'a' && c <= 'z' ) c = c + 'A' - 'a'; *p++ = c; } [/code] Start with looking at the ASM for …

Member Avatar for Salem
0
199
Member Avatar for brightstar

[url]http://www.daniweb.com/forums/announcement8-2.html[/url] Which is in response to your [URL="http://www.daniweb.com/forums/thread58984.html"]whining bump[/URL] of this year-old thread. Make an effort, even if it's just printing "welcome to ATM, enter PIN".

Member Avatar for Mr.Bling Bling
0
2K
Member Avatar for aliase

Well the cleanest thing to do would be to send a "quit" message from the client to the server. The server can then do an orderly shut-down. Instead of spraying machine-gun fire all over the system with your attempts to kill random processes.

Member Avatar for Salem
0
94
Member Avatar for Iam3R

You need VMS [url]http://www.angelfire.com/mo3/martin0/c/c_intro.html[/url] [quote] The return 0 is important. The zero is the exit status of the program, which can be interrogated by the caller. Zero is guaranteed to indicate success in the operating system being used. On UNIX, 0 indicates success, so no change is made. On DEC …

Member Avatar for nezachem
0
226
Member Avatar for Nerathas

> Console.Write("1"); // --> should not be here Into [code] // Console.Write("1"); // --> isn't here any more! [/code]

Member Avatar for ddanbe
0
115
Member Avatar for miYn2o0

> I have a wireless camera with RGB (RCA) exit cable (PAL) Posting links to your specific model might help cut out a lot of the guessing on our part. [url]http://en.wikipedia.org/wiki/OpenCV[/url]

Member Avatar for miYn2o0
0
261
Member Avatar for designsecrets

Good Cop: You've done good to get that far (and you used code tags). It shouldn't be that hard to take the code you've written (and the experience you gained writing it) to make it do something slightly different. Bad Cop: You found the code on the net (or it …

Member Avatar for Nick Evan
0
159
Member Avatar for Lylywhatever

Post your latest effort. [url]http://www.daniweb.com/forums/announcement114-2.html[/url]

Member Avatar for vegaseat
-1
105
Member Avatar for gkaykck

> int det(int); Fix this so it looks like your definition of the function. > int a,k,i,length,[COLOR="Red"]minor[/COLOR][10][10]; Pick a different name - it's the same as your function.

Member Avatar for gkaykck
0
145
Member Avatar for theideaofevil

> add $t5, $s0, $a0 #address of Buffer[i] in $t5 You're using the same index for both. [ICODE]buffer[j] = buffer[i];[/ICODE] j lags behind i for every non-valid character you come across. Don't forget to put the \0 in the right place when you're done.

Member Avatar for theideaofevil
0
3K

The End.