Search found 4886 matches

by EvanED
Wed Jul 22, 2015 1:43 pm UTC
Forum: The Help Desk
Topic: Definitions clarification — monolithic kernel/microkernel
Replies: 4
Views: 3514

Re: Definitions clarification — monolithic kernel/microkerne

I'm with WanderingLinguist; "task" doesn't have a single formal definition. The quote is accurate with respect to process. As used in your quote, "task" just means what is being done at a high level -- e.g. process scheduling is probably a task, I/O scheduling is a task, translat...
by EvanED
Fri Jul 17, 2015 6:23 pm UTC
Forum: Coding
Topic: Want to learn assembly through C.
Replies: 17
Views: 11638

Re: Want to learn assembly through C.

I have no idea what you're asking.

You say you want to use C to learn assembly, but then you ask for a decompiler for C++. You're also asking for a decompiler, but do you really want a disassembler? What are you trying to do?
by EvanED
Sun Jul 12, 2015 5:06 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9890
Views: 1830333

Re: Coding: Fleeting Thoughts

Inside that function, the log of foo is assigned to b. A throwaway function is defined which takes the log of its input and divides it by the newly calculated b. This throwaway function is "returned" by logBasen. So, when logBasen is called with foo as the argument, the thing that actuall...
by EvanED
Sun Jul 12, 2015 3:23 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9890
Views: 1830333

Re: Coding: Fleeting Thoughts

Can I just call it "argument binding"/"function wrapping" or is that too specific? It's not a terrible way of thinking about it, but I'd say it's a bit too specific. In practice, usually closures are doing more than just wrapping another function call and you'd put the logic fro...
by EvanED
Sun Jul 12, 2015 5:03 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9890
Views: 1830333

Re: Coding: Fleeting Thoughts

It looks like this is all tied up in the idea of never letting functions take more than one variable. It doesn't have to be restricted to one, you could have it take more than that. Thesh gave an example, but I'll give another one of something that I wrote a week or two ago. (Unfortunately, my exam...
by EvanED
Sat Jul 11, 2015 6:19 am UTC
Forum: Coding
Topic: Allocating on the stack: re- vs. pre-
Replies: 7
Views: 3237

Re: Allocating on the stack: re- vs. pre-

The fact that it's a VLA though... I'm not so sure. Unfortunately, I suspect it will allocates and deallocates the extra stack space each loop iteration. n probably doesn't matter except that if the compiler can establish that it is definitely less than 4096 or thereabouts it can probably do a more...
by EvanED
Sat Jul 11, 2015 4:11 am UTC
Forum: Coding
Topic: Allocating on the stack: re- vs. pre-
Replies: 7
Views: 3237

Re: Allocating on the stack: re- vs. pre-

Ordinarily I would say: With no initializer on the array, I would not be surprised if the code generated for each case is identical. The fact that it's a VLA though... I'm not so sure. Unfortunately, I suspect it will allocates and deallocates the extra stack space each loop iteration. n probably do...
by EvanED
Sun Jun 28, 2015 2:23 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9890
Views: 1830333

Re: Coding: Fleeting Thoughts

"There are only two hard problems in computer science: cache coherence, naming things, and off-by-one errors."
by EvanED
Sat Jun 20, 2015 11:13 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9890
Views: 1830333

Re: Coding: Fleeting Thoughts

You may or may not see this, but I'll write it anyway. :-) Re C vs. C++: Point taken. However, I thought I had heard that any C program will run on a C++ compiler also? Very nearly, but not 100%. (Actually, probably almost no C program will compile as C++ unless it was written with that in mind, but...
by EvanED
Sat Jun 20, 2015 7:34 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9890
Views: 1830333

Re: Coding: Fleeting Thoughts

I haven't really fully grasped how Java handles generics and polymorphism, and I'm not so sure I want to. I have more interest in seeing how it's done in C. C handles generics and polymorphism with it's "fuck you go use another language you hippie" feature. (No, seriously. It provides no ...
by EvanED
Fri Jun 19, 2015 3:09 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9890
Views: 1830333

Re: Coding: Fleeting Thoughts

Did you maybe intend to say the converse of what you said? No. It was something along the line of: O(1) space => there is a finite bound on the memory space => there is a finite bound on the state space => there is a fine bound on the length of a path through that space before repeating => repeats ...
by EvanED
Fri Jun 19, 2015 2:41 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9890
Views: 1830333

Re: Coding: Fleeting Thoughts

If an algorithm runs with space complexity O(1) ... If an algorithm has O(1) space complexity, it also has O(1) time complexity. That doesn't sound right. What about this algorithm? def silly (array) { for i in array: pass } By my count, that runs in O(n) time and does no allocations, therefore O(1...
by EvanED
Fri Jun 19, 2015 1:09 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9890
Views: 1830333

Re: Coding: Fleeting Thoughts

Dunno. Maybe it's just me. But is no-one else deeply unsettled by the notion of using Big-O in a finite domain (as is all computers) -- and a pretty damn small finite domain at that? No, because calling it a small finite domain is not even close to accurate. Also, when you get higher than P, even v...
by EvanED
Thu Jun 18, 2015 7:43 pm UTC
Forum: Gaming
Topic: Great Steam Deals (And other Online Distribution Systems)
Replies: 2634
Views: 494592

Re: Great Steam Deals (And other Online Distribution Systems

And Gunpoint is kind of fun... clever as far as it lasts, and has a brilliant sort of twisted-noir sense of humour, but I played the game and felt that it didn't really have enough content. Gunpoint was short but sweet. I forgot how funny it is though, until you said that. I was sold on it by the t...
by EvanED
Thu Jun 18, 2015 3:51 am UTC
Forum: Computer Science
Topic: If I want to grok MarI/O, where do I begin?
Replies: 10
Views: 5837

Re: If I want to grok MarI/O, where do I begin?

It's also not too hard to set up and run yourself. What it really needs, though, is a "that was funny/cool" button that saves the last network or two so you can go back and replay it later... there's a very high density of boring, crap attempts, but every now and again it produces somethin...
by EvanED
Thu Jun 18, 2015 1:57 am UTC
Forum: Computer Science
Topic: If I want to grok MarI/O, where do I begin?
Replies: 10
Views: 5837

Re: If I want to grok MarI/O, where do I begin?

Yup. A genetic algorithm is super trivial: A genetic algorithm is; one that works may or may not be, depending on application area. You have to pick the right features, you have to have a problem that can be solved by your abstraction, that solution has to be small enough that you can get to it in ...
by EvanED
Wed Jun 17, 2015 12:26 am UTC
Forum: Gaming
Topic: Great Steam Deals (And other Online Distribution Systems)
Replies: 2634
Views: 494592

Re: Great Steam Deals (And other Online Distribution Systems

Deus Ex series 80% off for the next 4 1/2 hours on Steam; $6.59 for all of Deus Ex, Invisible War, Human Revolution Director's Cut, and The Fall.
by EvanED
Mon Jun 15, 2015 11:23 pm UTC
Forum: Computer Science
Topic: If I want to grok MarI/O, where do I begin?
Replies: 10
Views: 5837

Re: If I want to grok MarI/O, where do I begin?

Yeah, genetic algorithms are quite simple conceptually. Any difficulties come in how you combine multiple offspring; it can be non-obvious how to do that. I didn't follow the links, but I suspect combining neural nets is the main contribution of his references. Then the main thing he did probably wa...
by EvanED
Sat Jun 13, 2015 9:29 pm UTC
Forum: Computer Science
Topic: How is physical access not a factor in 2-factor?
Replies: 13
Views: 7085

Re: How is physical access not a factor in 2-factor?

(Also, if we're talking about just the terms "1" vs "2" factor, I think "compromise Verizon" should probably count as a second factor. :-)) the issue is that the SMS probably goes through more than just Verizon, is not end-to-end encrypted, and can be easily suppressed...
by EvanED
Sat Jun 13, 2015 9:16 pm UTC
Forum: Computer Science
Topic: How is physical access not a factor in 2-factor?
Replies: 13
Views: 7085

Re: How is physical access not a factor in 2-factor?

Pessimistic? Paranoid? Sure. But experience should have taught us that these things do happen when the protected systems are worth enough. I'm not saying one shouldn't be a somewhat paranoid, but what you're talking about is still orders of magnitude more difficult than a normal 1-factor database a...
by EvanED
Fri Jun 12, 2015 5:48 am UTC
Forum: Coding
Topic: Project Euler
Replies: 411
Views: 152711

Re: Project Euler

the getter/setter idiom is an antipattern because it is inherently nonorthogonal. It's just a coincidence that the specific example is not a rational class. I don't think that's there at all! He's not saying getter/setters are bad, he's saying think about what your design is and...
by EvanED
Thu Jun 11, 2015 4:27 pm UTC
Forum: Coding
Topic: Project Euler
Replies: 411
Views: 152711

Re: Project Euler

(offtopic) This (Fraction) is the first custom class I have written in Java. (I mean, the first class that's actually designed to be instantiated. Of course everything is in a class in Java. But you know what I mean.) Anyone see any holes in it? :) This is poor interface design, as explained in cha...
by EvanED
Thu Jun 11, 2015 3:45 pm UTC
Forum: Computer Science
Topic: How is physical access not a factor in 2-factor?
Replies: 13
Views: 7085

Re: How is physical access not a factor in 2-factor?

Your cell phone is something that you have , but SMS is not exactly a confidential communications channel, so it's not a reliable way to verify whether you actually have the item in question. Harder to beat than 1-factor, but not quite 2-factor yet. I think that's a very pessimistic view. I can ima...
by EvanED
Wed Jun 03, 2015 10:09 pm UTC
Forum: Computer Science
Topic: Deliberately bad algorithms
Replies: 120
Views: 50118

Re: Deliberately bad algorithms

That reminds me of SlowSort (not an alias of bogosort) For purposes of readability... def slowsort(A, i, j): # This procedure sorts the subarray A[i]...A[j] if i >= j: return m = (i+j)/2 slowsort(A, i, m) slowsort(A, m+1, j) if A[m] > A[j]: A[m],A[j] = A[j],A[m] slowsort(A, i, j-1)
by EvanED
Wed Jun 03, 2015 12:18 am UTC
Forum: Computer Science
Topic: Deliberately bad algorithms
Replies: 120
Views: 50118

Re: Deliberately bad algorithms

Guaranteed to terminate successfully with P = 1, but it's impossible to derive an O notation since the running time has no upper bound. You can still talk about the complexity of the average case, which would be n! iterations of the outer loop. factorial = product . enumFromTo 1 isPrime n = factori...
by EvanED
Wed Jun 03, 2015 12:14 am UTC
Forum: The Help Desk
Topic: Linux equivalent of Windows's calc?
Replies: 6
Views: 5727

Re: Linux equivalent of Windows's calc?

bc ? it doesn't have a way to limit the width of calculations, but you can just do something like "(...)%2^16". for more advanced calculations, "obase=16;-256" produces -100. (And yes, I could do the 2's complement arithmetic manually. The point of this is to avoid that.) gp is ...
by EvanED
Tue Jun 02, 2015 11:01 pm UTC
Forum: The Help Desk
Topic: Linux equivalent of Windows's calc?
Replies: 6
Views: 5727

Linux equivalent of Windows's calc?

OK, this seems like the most absurd question ever, I know, but I've tried a few different options and, at least at the level I've seen (which admittedly has been a pretty cursory look) nothing matches my bill. What I want is something like the "programmer" mode of Windows calc. This lets y...
by EvanED
Mon Jun 01, 2015 7:14 am UTC
Forum: Computer Science
Topic: Mind Blowing Algorithms
Replies: 76
Views: 27693

Re: Mind Blowing Algorithms

Linked-node data structures are almost always horrible ideas. Every step when traversing them is a nearly guaranteed cache miss. ... Or, in short, the default container you should use is a std::vector. If your problem isn't suitable for using a std::vector, change the problem. This is something tha...
by EvanED
Sat May 30, 2015 4:02 pm UTC
Forum: Coding
Topic: Useful applications of recursion?
Replies: 19
Views: 4825

Re: Useful applications of recursion?

And recursive data structures can still be dealt with via loops and stacks/queues... it's a matter of what constraints (i.e. memory/storage) are placed on the solution, no? Yes, they can, but (at least IMO) doing so is often a PITA and makes for far less clear code than the recursive version. If yo...
by EvanED
Fri May 29, 2015 2:46 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9890
Views: 1830333

Re: Coding: Fleeting Thoughts

The only one I really disagree with is the graphs - neither excel nor libreoffice produces graphs that are better than terrible without a lot of settings tweaks. Huh? I mean, sure, both provide ways to generate some really awful graphs. But here is some random data I just threw together with localc...
by EvanED
Fri May 29, 2015 12:10 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9890
Views: 1830333

Re: Coding: Fleeting Thoughts

Spreadsheets are mainly a grid layout tool for information. That is their primary purpose. They are electronic grid paper. The use of a spreadsheet for calculation is a mixture of the usefulness of that grid-based easy to modify UI (make input cells red!), and its push-pull calculation model. Layou...
by EvanED
Fri May 22, 2015 3:07 pm UTC
Forum: Computer Science
Topic: Fleeting Thoughts (CS Edition)
Replies: 99
Views: 67393

Re: Fleeting Thoughts (CS Edition)

Xenomortis wrote:Unless you're following a tutorial/book tailored for the IDE you're using, confusion will befall you.
Well, but that's true of compilers at the command line too. In fact, I'd say it's worse... at least you have a chance of bumbling into the right answer just playing around with the IDE.
by EvanED
Fri May 22, 2015 6:44 am UTC
Forum: Computer Science
Topic: Fleeting Thoughts (CS Edition)
Replies: 99
Views: 67393

Re: Fleeting Thoughts (CS Edition)

IDE's are useful, but tend to be a bit heavy for when you're starting out - when you're learning the basics, you largely just want "source file -> compiler -> executable", not "solution + projects -> build...". Could you expand on that?? My understanding of IDEs is limited, but ...
by EvanED
Mon Apr 06, 2015 4:38 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9890
Views: 1830333

Re: technomancy: Fleeting Thoughtth

Also, I don't think I posted thith here. I did a talk at the London Ruby User Group. It's about the weird bits of ruby, and it's ~10 minutes. Here it is. Any feedback welcome! Just took a look. FWIW, I use the "adjacent strings get concatenated" thing in C++ with some frequency, because i...
by EvanED
Tue Mar 31, 2015 2:45 pm UTC
Forum: Coding
Topic: Javascript/HTML help
Replies: 14
Views: 4143

Re: Javascript/HTML help

I've played with JS some, but never jQuery. jQuery is a good tool if you need to support older browsers. If you're only developing for yourself or people with current browsers, html5's javascript API is just as powerful (and has better performance!). I don't want to go so far as tie it to Chrome sp...
by EvanED
Tue Mar 31, 2015 3:27 am UTC
Forum: Coding
Topic: Javascript/HTML help
Replies: 14
Views: 4143

Re: Javascript/HTML help

Well, to start with, it might make a difference if you put sizes (width and height) on the images. If you don't, then once the images load and the size is known, I think it has to re-wrap the page with the new size. That's a good point. I knew that, but it slipped my mind here. Edit 2: How comforta...
by EvanED
Mon Mar 30, 2015 9:30 pm UTC
Forum: Coding
Topic: Javascript/HTML help
Replies: 14
Views: 4143

Re: Javascript/HTML help

This is hopefully suitably anonymized that no one will get on me too badly. :-) <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"> <html> <head> <meta name="generator" content= "HTML Tidy for Linux (vers 25 March 2009), see www.w3.org"> <title>xxxxxxxxx</title> ...
by EvanED
Mon Mar 30, 2015 8:22 pm UTC
Forum: Coding
Topic: Javascript/HTML help
Replies: 14
Views: 4143

Re: Javascript/HTML help

I'm not primarily a web developer myself, but there are some tools available that may help. If you are using Chrome, try View->Developer->Developer Tools. In the timeline tab, click the record button, then reload the page then click the record button again to stop. This will show you a timeline of ...
by EvanED
Mon Mar 30, 2015 2:52 pm UTC
Forum: Hardware
Topic: Help Finding MP3 Player
Replies: 10
Views: 9655

Re: Help Finding MP3 Player

Jorpho wrote:And, being new here, I'm not sure how you've gauged the orientation of this board?
Low post count doesn't necessarily mean new; people lurk. And look at the joined date.
by EvanED
Sun Mar 29, 2015 4:37 am UTC
Forum: Coding
Topic: Javascript/HTML help
Replies: 14
Views: 4143

Re: Javascript/HTML help

Frames are a good suggestion; you don't see them much (at least full framesets) so I didn't think about that. That could work well. I can probably post an example file to see if there are some simplifications that can be made to make it render faster; I'll try to do that tomorrow. It wouldn't surpri...

Go to advanced search