Click here to Skip to main content

Comments by CPallini (Top 200 by date)

CPallini at 2 days ago View
   
What system are you using? As far as I know, on modern OSs memory is allocated in pages. A contiguous block in process space isn't necessarily mapped to a contiguous block of physical memory.
CPallini at 2 days ago View
   
Did you ever play cards? Extracting some cards from a deck is a simple example of such process.
CPallini at 2 days ago View
   
You could at least provide the name of the API function.
CPallini at 3 days ago View
   
Possibly not OOP, however, with class!
CPallini at 3 days ago View
   
Why cannot you?
CPallini at 3 days ago View
   
You did not add the buttons to the form.
CPallini at 3 days ago View
   
What do you mean with "it doesn't work" ?
CPallini at 4 days ago View
   
Thank you, Maciej.
CPallini at 4 days ago View
   
Merry Christmas to you, Richard!
CPallini at 4 days ago View
   
5.
CPallini at 4 days ago View
   
5.
CPallini at 4 days ago View
   
5.
CPallini at 4 days ago View
   
Thank you.
CPallini at 4 days ago View
   
Thank you.
CPallini at 20-Dec-14 10:01am View
   
5.
CPallini at 20-Dec-14 10:01am View
   
5.
CPallini at 19-Dec-14 16:03pm View
   
Shameless Self Promotion? :-) Have my 5.
CPallini at 19-Dec-14 16:02pm View
   
5.
CPallini at 19-Dec-14 15:57pm View
   
I see the answer in the posted code, so?
CPallini at 19-Dec-14 8:24am View
   
And numbered array indices didn't help you... :-)
CPallini at 18-Dec-14 6:45am View
   
Thank you.
CPallini at 17-Dec-14 15:23pm View
   
You know, without the end of the line a ReadLine method steadily refuses to return.
CPallini at 17-Dec-14 15:04pm View
   
Yes.
CPallini at 17-Dec-14 13:49pm View
   
I see no newline in server response.
CPallini at 17-Dec-14 9:21am View
   
5.
CPallini at 17-Dec-14 7:35am View
   
Text is already binary, you know. What are you trying to do, exactly?
CPallini at 17-Dec-14 6:55am View
   
"is any .DLL or service for build and execute apk file from source code ???"
Yes, it's called compiler (plus apk packager, I suppose).
By definition a compiler produces executables from source codes.
CPallini at 16-Dec-14 13:59pm View
   
Sorry?
CPallini at 16-Dec-14 12:26pm View
   
Being the answer to 'how many steps are required ?', I think zero is the correct answer.
CPallini at 16-Dec-14 12:26pm View
   
Thank you!
CPallini at 16-Dec-14 8:49am View
   
:-)
CPallini at 16-Dec-14 8:49am View
   
You are welcome.
CPallini at 16-Dec-14 8:49am View
   
Thank you.
CPallini at 16-Dec-14 8:27am View
   
That's it, 5.
CPallini at 16-Dec-14 6:50am View
   
Testing.
Please note that's really a poor question.
CPallini at 16-Dec-14 6:49am View
   
I see out of array bounds in your code. By the why, you should post the code here.
CPallini at 16-Dec-14 3:27am View
   
Thank you, Sergey.
CPallini at 15-Dec-14 7:00am View
   
Have my 5 for balancing.
CPallini at 15-Dec-14 6:52am View
   
For example, a MP is a delegate.
CPallini at 15-Dec-14 5:15am View
   
5.
CPallini at 15-Dec-14 3:00am View
   
Could you please provide a sample input (and possibly the expected output)?
CPallini at 14-Dec-14 10:39am View
   
You passed to CreateResampledBitmap 1024x768 as resampling size, why then you called BitBlt passing 4700x4700 ?
BTW, the library is not able to handle such a huge (4700x4700) image.
CPallini at 12-Dec-14 7:48am View
   
Yes, of course.
CPallini at 9-Dec-14 16:01pm View
   
It is an almost trivial task...
CPallini at 5-Dec-14 8:55am View
   
What do you mean with 'vector'?
You know, C++ has both objects and vectors, C has none of them.
CPallini at 4-Dec-14 15:12pm View
   
Thank you.
CPallini at 4-Dec-14 14:51pm View
   
Of course, you have to know what you are doing.
CPallini at 4-Dec-14 7:56am View
   
What are you doing?
CPallini at 3-Dec-14 15:56pm View
   
Thank you.
CPallini at 3-Dec-14 15:56pm View
   
Nope, of course.
CPallini at 3-Dec-14 15:32pm View
   
I know that (at least the general idea, I didn't elaborate), however it looked to me a bit too 'advanced' for the OP (this is just a persona opinion, of coourse).
I any case, great, well done, have my 5.
CPallini at 3-Dec-14 8:09am View
   
5. Nice.
CPallini at 3-Dec-14 6:23am View
   
There's nothing you can do to speed up the eclipse.
CPallini at 3-Dec-14 4:30am View
   
You are welcome.
CPallini at 3-Dec-14 4:17am View
   
5.
CPallini at 3-Dec-14 4:14am View
   
5.
CPallini at 2-Dec-14 13:58pm View
   
Thank you Maciej!
CPallini at 2-Dec-14 11:35am View
   
OK, it took me a while to answer, so?
:-D
CPallini at 2-Dec-14 8:58am View
   
This is plain wrong, C/C++ have no 'byte' as builtin type.
CPallini at 30-Nov-14 11:48am View
   
Could you please elaborate?
CPallini at 29-Nov-14 5:51am View
   
It always does.
CPallini at 28-Nov-14 13:37pm View
   
I keep voting 5, but nothing happens (I'm not drunk, yet :-) ).
CPallini at 28-Nov-14 13:05pm View
   
Sorry, I intended 5 but clicked on 4. Sorry again.
OK, looks fixed now.
CPallini at 28-Nov-14 9:45am View
   
Wow. 5.
CPallini at 27-Nov-14 13:12pm View
   
It happens: it happened to me too. :-O
You are welcome.
CPallini at 27-Nov-14 3:48am View
   
Why should we suggest you how to write possibly malicious code?
CPallini at 26-Nov-14 9:32am View
   
?
CPallini at 26-Nov-14 7:21am View
   
Thanks :-)
CPallini at 26-Nov-14 4:10am View
   
Of course Microsoft C# is not open source, however there is a open source implementation, called Mono, based on the ECMA standard. The mostly widely used scripting language is possibly javascript.
CPallini at 23-Nov-14 6:58am View
   
Your code compiles fine (just a couple of warnings) and executes fine on my system.
CPallini at 21-Nov-14 2:46am View
   
5.
CPallini at 19-Nov-14 13:25pm View
   
Your code doesn't work because the upper limit of the inner for loop is wrong (it should be 999).
CPallini at 19-Nov-14 3:23am View
   
Thank you.
CPallini at 19-Nov-14 2:17am View
   
Please elaborate.
CPallini at 17-Nov-14 4:03am View
   
5.
CPallini at 17-Nov-14 3:19am View
   
5. :-)
CPallini at 16-Nov-14 11:59am View
   
5. I suppose you are right, OP has to reverse a C string 'in-place'.
CPallini at 15-Nov-14 16:55pm View
   
Good answer, my 5. Now, Sir, where is the question? :-D :-D :-D
CPallini at 14-Nov-14 16:21pm View
   
Thank you, Sergey.
CPallini at 14-Nov-14 15:35pm View
   
You are welcome.
CPallini at 14-Nov-14 4:06am View
   
'not working' is poorly informative. Please detail what is the misbehavior.
CPallini at 14-Nov-14 3:35am View
   
Thank you.
CPallini at 13-Nov-14 8:39am View
   
That's it, my 5.
CPallini at 13-Nov-14 5:09am View
   
You are welcome.
CPallini at 13-Nov-14 4:21am View
   
Sorry I misread your question (thinking you considered classic ASP technology). I am going to delete my answer. Sorry again for the inconvenience.
CPallini at 13-Nov-14 4:21am View
   
Deleted
Sorry I misread your question (thinking you considered classic ASP technology). I am going to delete my answer. Sorry again for the inconvenience.
CPallini at 11-Nov-14 7:49am View
   
5.
CPallini at 10-Nov-14 11:47am View
   
Well, the hint is in the name.
CPallini at 10-Nov-14 11:40am View
   
Don't you trust the documentation?
CPallini at 8-Nov-14 3:04am View
   
5.
CPallini at 6-Nov-14 7:00am View
   
Deleted
The Unicode/ASCII mismatch occurs withe the %s format specifier.
CPallini at 31-Oct-14 16:44pm View
   
You cannot: there is not a royal way to C++.
CPallini at 31-Oct-14 16:42pm View
   
5.
CPallini at 31-Oct-14 16:41pm View
   
Exactly!
CPallini at 31-Oct-14 11:54am View
   
What's the purpose of the first code? Shouldn't it check the input file? Then make a function (not main function) with it and call it from the secodn code (you are doing the opposite).
CPallini at 31-Oct-14 10:48am View
   
I suggested the opposite.
Please note your code would call recursively process.
CPallini at 31-Oct-14 10:30am View
   
Post your code together with the exact error message.
CPallini at 31-Oct-14 10:21am View
   
My 5.
CPallini at 31-Oct-14 10:14am View
   
What would be the use of the return value of printf?
CPallini at 31-Oct-14 10:01am View
   
5. The C++ way.
CPallini at 31-Oct-14 10:00am View
   
5. The C way.
CPallini at 31-Oct-14 4:25am View
   
I suppose the OP automaton (in its simplest form) should parse a grammar like:
g := "aa" | "bb"
CPallini at 30-Oct-14 7:00am View
   
Thank you, Sergey.
CPallini at 30-Oct-14 7:00am View
   
I really wish to help you. Could you please post the exact code you tried and the exact error message?
CPallini at 30-Oct-14 6:59am View
   
Thank you.
CPallini at 29-Oct-14 16:49pm View
   
Yes, Chrome, for instance, works that way.
CPallini at 29-Oct-14 16:45pm View
   
Yes, I fully agree with you. As matter of fact I often suggest a Wikipedia page.
CPallini at 29-Oct-14 16:33pm View
   
I really don't know, but I like your question title.
CPallini at 29-Oct-14 16:27pm View
   
I suppose you are stuggesting Wikipedia is a handy starting point :-)
My 5.
CPallini at 29-Oct-14 16:23pm View
   
My 5, because it contains good explanations.
However I disagree on your first point. It could be multiple executables. It all depends on the amount of communication required by the different processes.
CPallini at 29-Oct-14 16:21pm View
   
printf!
CPallini at 29-Oct-14 16:20pm View
   
Yes, it could be, at least accordingly to this page:
http://homepage.ntlworld.com/jonathan.deboynepollard/FGA/legality-of-void-main.html
By the way, thank you!
CPallini at 29-Oct-14 10:39am View
   
5!
CPallini at 28-Oct-14 13:14pm View
   
Thank you.
CPallini at 28-Oct-14 13:01pm View
   
WoW!
5.
CPallini at 28-Oct-14 13:00pm View
   
Thank you, Maciej.
CPallini at 28-Oct-14 12:39pm View
   
Have you administration privileges on the machine?
CPallini at 28-Oct-14 12:32pm View
   
Could you please detail your scenario?
CPallini at 28-Oct-14 12:31pm View
   
Thank you.
CPallini at 28-Oct-14 12:20pm View
   
5.
CPallini at 28-Oct-14 8:41am View
   
OK, you have not encryption code. So how do you encrypt the data? Are you using an external tool?
CPallini at 28-Oct-14 7:19am View
   
You should also post the code you are using for encryption.
CPallini at 28-Oct-14 7:18am View
   
Deleted
You should also post the code you use for encryption.
CPallini at 28-Oct-14 7:17am View
   
If you are reading characters from a file (or multiple files) then you have to read chunks of them in order to maximize performance.
CPallini at 28-Oct-14 7:13am View
   
OK, I'm going to remove my answer, since yours already gives the correct format specifier.
CPallini at 28-Oct-14 6:52am View
   
And the question is?
CPallini at 28-Oct-14 6:51am View
   
What is the exact error message?
CPallini at 28-Oct-14 3:30am View
   
5.
CPallini at 27-Oct-14 12:31pm View
   
No, it is not possible.
CPallini at 27-Oct-14 12:31pm View
   
No, it is not possible.
CPallini at 27-Oct-14 10:11am View
   
unsigned char dt []=a;
Is of course wrong. What are trying to do?
CPallini at 27-Oct-14 9:07am View
   
Probably your code is wrong. We cannot guess what is happening from your description, though.
CPallini at 26-Oct-14 10:43am View
   
Provided Socket is a file descriptor (that is a int) the line
write(Socket, dt, 2);
should compile fine. What is the exact error message you are getting?
CPallini at 26-Oct-14 10:21am View
   
Thank you, Maciej!
CPallini at 26-Oct-14 9:34am View
   
Thank you.
You got my five too.
CPallini at 26-Oct-14 9:27am View
   
Pseudo code is not much different fro the actual one (at least in this case) what's your problem with it?
CPallini at 24-Oct-14 15:33pm View
   
5.
CPallini at 24-Oct-14 15:33pm View
   
5, of course.
CPallini at 24-Oct-14 11:26am View
   
Assuming you know how the for loop works, what's the confusing part of round robin algorithm?
CPallini at 24-Oct-14 9:34am View
   
Nice, 5.
CPallini at 24-Oct-14 9:33am View
   
Thank you.
CPallini at 24-Oct-14 3:32am View
   
5.
CPallini at 22-Oct-14 16:11pm View
   
You should be more precise. For instance what do you mean with 'draw objects'? Do you want to draw shapes on the screen?
CPallini at 22-Oct-14 14:09pm View
   
No one, but Knuth, is able to create 'all types of software', my dear.
CPallini at 22-Oct-14 14:00pm View
   
In order to get a meaningful answer you should detail what you mean with 'System Software'. Would you build your own operative system?
CPallini at 22-Oct-14 13:44pm View
   
Yes, you may as well use a regular cast in this case.
CPallini at 22-Oct-14 4:02am View
   
'Charles'
LOL
CPallini at 21-Oct-14 15:19pm View
   
GetClientRect returns, exactly, the client area rectangle (borders are not included a far as I know).
CPallini at 21-Oct-14 9:03am View
   
Yes, you are right. A read only TextBox also would fit the job.
CPallini at 21-Oct-14 8:37am View
   
You may post a link to a file posted in a image sharing site (like, for instance, flickr). You could also post the exact error message, usually it is pretty informative.
CPallini at 21-Oct-14 7:48am View
   
You are welcome.
CPallini at 21-Oct-14 7:41am View
   
Why should the executable read such INI file (we know nothing about the executable)?
CPallini at 21-Oct-14 7:31am View
   
5.
CPallini at 21-Oct-14 7:08am View
   
5.
CPallini at 21-Oct-14 7:07am View
   
Could you please show the exact type of Token.CP?
CPallini at 21-Oct-14 7:05am View
   
Please remove this solution.
CPallini at 21-Oct-14 6:41am View
   
You are welcome.
CPallini at 21-Oct-14 6:39am View
   
That does not mean main would be void (void main() is illegal in C++).
main; always return an int, an implicit return 0; is added by the compiler. You cannot change the main prototype.
CPallini at 20-Oct-14 17:47pm View
   
main must return an int in C++.
CPallini at 20-Oct-14 16:26pm View
   
What?
CPallini at 20-Oct-14 16:25pm View
   
Are you kidding?
CPallini at 20-Oct-14 16:24pm View
   
What is the offending line?
CPallini at 20-Oct-14 16:23pm View
   
In C++
return 0;
is redundant as it is implicitely assumed as main exits. See
http://en.cppreference.com/w/cpp/language/main_function
(point 4)
CPallini at 20-Oct-14 16:01pm View
   
Hence return 0; is inaccettable too. :-)
CPallini at 20-Oct-14 13:59pm View
   
I've balanced the univote.
CPallini at 20-Oct-14 13:58pm View
   
I suppose you have to post the actual code.
CPallini at 20-Oct-14 13:56pm View
   
Moreover, if (finalScore < 60) is useless too. :-)
CPallini at 20-Oct-14 13:52pm View
   
However they are harmless.
CPallini at 20-Oct-14 13:52pm View
   
The posted code compiles fine on my system.
CPallini at 20-Oct-14 5:49am View
   
5.
CPallini at 20-Oct-14 3:07am View
   
How could we help without seeing your code?
CPallini at 20-Oct-14 3:05am View
   
5.
CPallini at 19-Oct-14 10:26am View
   
Really I don't know. I just moved your comment here (it is not a solution).
CPallini at 19-Oct-14 9:22am View
   
5.
CPallini at 19-Oct-14 9:22am View
   
[On behalf of the OP]
Sergey Alexandrovich Kryukov
Thank you for your great explanation Smile | :)
That's great!
But, how to program in Binary Code for x86 Processor ?
CPallini at 17-Oct-14 8:28am View
   
Yes, I've deleted my post.
CPallini at 17-Oct-14 8:06am View
   
There is no division in the OP code.
CPallini at 17-Oct-14 3:34am View
   
The posted code doesn't show how to use the methods.
CPallini at 16-Oct-14 15:52pm View
   
5.
CPallini at 16-Oct-14 15:12pm View
   
How could you implement it without having access to source code?
CPallini at 16-Oct-14 15:04pm View
   
Great link, my virtual 5.
CPallini at 15-Oct-14 3:38am View
   
5.
CPallini at 15-Oct-14 3:11am View
   
Cannot you remove the wrong entry and use just the right one?
CPallini at 14-Oct-14 15:38pm View
   
Thank you!
CPallini at 14-Oct-14 7:58am View
   
Thank you!
CPallini at 14-Oct-14 6:23am View
   
5.
CPallini at 14-Oct-14 4:20am View
   
5.
CPallini at 14-Oct-14 3:26am View
   
"I have managed to recieve this output :"
It should simple then to manage it in order to receive the expected output, that is the representation of a multidimensional array.
CPallini at 13-Oct-14 3:46am View
   
5.
CPallini at 9-Oct-14 13:51pm View
   
My 5.
CPallini at 9-Oct-14 13:46pm View
   
Right, my 5. At least he could divide is (supposing) text file in blocks corresponding to the ones required by the encryption algorithm.
CPallini at 9-Oct-14 9:34am View
   
My virtual 5.
CPallini at 8-Oct-14 12:18pm View
   
Don't sure I got it. Anyway, if you need unbuffered input then it is not so simple, because it is platform-dependent. See, for instance:
http://stackoverflow.com/questions/9957721/how-is-stdiostream-buffered
CPallini at 8-Oct-14 10:31am View
   
If you need a char why don't you call cin.get?
http://www.cplusplus.com/reference/istream/istream/get/
CPallini at 8-Oct-14 6:03am View
   
.odt is actually an OpenOffice file. As far as I know, you have to open it in binary mode, unzip it, and then parse the XML content.
If yoou actually need a plain text file then don't use OpenOffice (or, on saving, choose .txt file format, if it allows you), use instead a text editor, like, for instance vi (or gedit).
CPallini at 8-Oct-14 4:39am View
   
Thank you.
CPallini at 6-Oct-14 16:30pm View
   
5.
CPallini at 6-Oct-14 16:29pm View
   
5.
CPallini at 6-Oct-14 15:58pm View
   
Dont' know why someone downvoted your solution, it looks a nice piece of code. Have my 5.
CPallini at 6-Oct-14 15:46pm View
   
Why aren't you sure? Isn't the documentation available to you? Haven't you a compiler?
(It looks right)

Advertise | Privacy | Mobile
Web04 | 2.8.141223.1 | Last Updated 1 Jan 1900
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid