Search found 7981 matches

by phlip
Sun Apr 16, 2017 5:15 am UTC
Forum: News & Articles
Topic: In other news... (humorous news items)
Replies: 13863
Views: 1813011

Re: In other news... (humorous news items)

Coyne wrote:
The requests would all be identical, right down to voice, inflection and timing. Could Google have technology that detects such problems and automatically defeats them?

If Twitter isn't lying to me, I believe they already have.
by phlip
Thu Apr 13, 2017 1:55 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9722
Views: 1501260

Re: Coding: Fleeting Thoughts

ahammel wrote:Anyway: the good news is that I found a tool to statically find import cycles. The bad news that the dependency cycle in question is 41 modules long.

Godspeed, brave warrior...
by phlip
Wed Apr 12, 2017 12:07 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9722
Views: 1501260

Re: Coding: Fleeting Thoughts

↶ Node's handling of cyclic dependencies is probably the most maddening language feature I've ever had to deal with. "Surprise! That function is suddenly undefined! Good luck figuring out why." That sounds very similar to the way it works in Python ... except for that word "copy"...
by phlip
Sat Apr 08, 2017 6:45 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9722
Views: 1501260

Re: Coding: Fleeting Thoughts

In that case, why all the messing around with subclasses and whatnot? Why do you need separate UnboundObj and BoundObj? Can't you just have SomeObj which has an unbind method, and if you call it while it isn't bound, it does nothing or raises an exception or whatever? What's the benefit in making it...
by phlip
Fri Apr 07, 2017 11:43 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9722
Views: 1501260

Re: Coding: Fleeting Thoughts

I don't think there's a good reason to be messing with __class__ here (or almost ever, really)... if you really wanted to do it that way, you could just set obj.unbind = lambda: binder().remove(obj) and then in remove just del obj.unbind Basically the only advantage of the automatic-subclassing stuf...
by phlip
Sun Apr 02, 2017 2:00 pm UTC
Forum: Computer Science
Topic: Deliberately bad algorithms
Replies: 120
Views: 31709

Re: Deliberately bad algorithms

(Very rough pseudocode...) for path in sys.path: for file in os.walk(path): __import__(file) for o in gc.get_objects(): if isinstance(o, types.FunctionType): try: o(seq) etc Every function. Who cares where it came from. Also, to go back a step... I've never seen "log² x" to mean "(log...
by phlip
Wed Mar 29, 2017 1:05 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9722
Views: 1501260

Re: Coding: Fleeting Thoughts

When I took CS theory, they called them "formal parameters" and "actual parameters", but they also said that "parameters" vs "arguments" gets some use.
by phlip
Sat Mar 25, 2017 1:47 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9722
Views: 1501260

Re: Coding: Fleeting Thoughts

Yeah, as Xenomortis alludes, the magic word here is single dispatch ... which method is actually called is based on the actual runtime type of the "this" parameter (ie: calling overridden methods in subclasses) but all of the other parameters are bound statically based off their declared t...
by phlip
Wed Feb 15, 2017 11:09 pm UTC
Forum: Individual XKCD Comic Threads
Topic: 1799: "Bad Map Projection: Time Zones"
Replies: 70
Views: 7436

Re: 1799: "Bad Map Projection: Time Zones"

↶ Maybe I'm misunderstanding something, but… why is Poland "reaching" to the east? It's in the same time zone as Germany and most of the Western Europe, and they observe DST the same way. Probably just so it can share a border with Belarus, which is two timezones away... ↶ I don't get tha...
by phlip
Sun Jan 29, 2017 11:12 am UTC
Forum: General
Topic: Thoughts for ships
Replies: 89691
Views: 5999081

Re: Random natterings

↶ Somewhere between a post I made back in June 2014 and now, a string of unlikely events came with an unexpected outcome. Shot for the moon, ended up with a star on a pedestal. Turns out the official measurement was 425cm; larger than I thought (Absolute max size on design was 424cm) and what they ...
by phlip
Thu Jan 19, 2017 11:53 am UTC
Forum: Science
Topic: Miscellaneous Science Questions
Replies: 2845
Views: 544116

Re: RELATIVITY QUESTIONS! (and other common queries)

morriswalters wrote:
Assume mirror A at the receiving end and that A reflects towards a target at B.

Sure, but someone at B won't get that reflected light from A until, by definition, lightspeed delay from A to B. A still can't do something to get information to B faster than light, is the point.
by phlip
Wed Jan 18, 2017 11:58 pm UTC
Forum: Science
Topic: Miscellaneous Science Questions
Replies: 2845
Views: 544116

Re: RELATIVITY QUESTIONS! (and other common queries)

Say you are at point A, and you know someone at point B. Is there literally anything you can do, that will have effects that B can measure? Is there any measurement B can make, where the results will differ depending (directly or indirectly) on actions you take? If so: there's a transmission of info...
by phlip
Sun Jan 15, 2017 3:24 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9722
Views: 1501260

Re: Coding: Fleeting Thoughts

It's also worth name-dropping Rice's theorem, a generalisation of the halting problem that any question like "is this a sorting algorithm" is undecidable.
by phlip
Wed Jan 11, 2017 12:10 pm UTC
Forum: Individual XKCD Comic Threads
Topic: 1784: "Bad Map Projection: Liquid Resize"
Replies: 58
Views: 6470

Re: 1784: "Bad Map Projection: Liquid Resize"

Copper Bezel wrote:
phlip wrote:Layer -> Liquid Rescale

That is where it appears, but I had to install the plugin explicitly.

Ah, good to know. On Ubuntu at least, it's bundled (as a part of the "gimp-plugin-registry" package).
by phlip
Wed Jan 11, 2017 11:14 am UTC
Forum: Individual XKCD Comic Threads
Topic: 1784: "Bad Map Projection: Liquid Resize"
Replies: 58
Views: 6470

Re: 1784: "Bad Map Projection: Liquid Resize"

↶ I don't get it, maybe because english is not my primary language. Just what is used to resize each country ?? I'm not asking about the tool, it's photoshop, ok. I'm guessing some kind of numeric quantity is "weighting" countries, but can't understand which... (maybe just "none"...
by phlip
Sun Jan 08, 2017 9:01 am UTC
Forum: General
Topic: Thoughts for ships
Replies: 89691
Views: 5999081

Re: Random natterings

↶ Question does using female as a noun when talking about woman sound as awkward to native speakers as it does to me? "Female" as a noun, I associate with basically a few contexts: (1) People working with animals, especially either (a) studying them, or (b) breeding them. (2) Ferengi, who...
by phlip
Fri Jan 06, 2017 10:34 pm UTC
Forum: News & Articles
Topic: In other news... (humorous news items)
Replies: 13863
Views: 1813011

Re: In other news... (humorous news items)

↶ Quick really tangential question: if the Moon was 225 miles away from the Earth, how heavy would it need to be to cause the tides? Well that's roughly 1000 times closer than the actual moon. Newtonian gravity varies inversely with distance squared. So I guess it would need to be roughly one milli...
by phlip
Thu Jan 05, 2017 5:17 am UTC
Forum: Logic Puzzles
Topic: Infinite Balls and Jugs [solution]
Replies: 611
Views: 68835

Re: Infinite Balls and Jugs [solution]

Offtopic electronics stuff: It comes up in electronics for looking at AC circuits... If every power source in the circuit is AC with the same frequency, then every voltage/current measurement will be a sine wave of that frequency (since the sum of any two sine waves of the same frequency is anot...
by phlip
Sun Jan 01, 2017 1:48 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9722
Views: 1501260

Re: Coding: Fleeting Thoughts

Yeah, had a brainfart there. 2 1024 is just the maximum number you can fit in a double at all, not range of integers in doubles. That cutover is at 2 52 to 2 53 . Every integer with absolute value less than 2 53 can be represented exactly as a double, and every double bigger than 2 52 is exactly an ...
by phlip
Sun Jan 01, 2017 2:52 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9722
Views: 1501260

Re: Coding: Fleeting Thoughts

↶ Maybe even more importantly, any operation on a float has to return another float, since the value may be outside the range representable by ints. What's intfloor(2147483649.5)? Well, we're talking about a language with bignums, so that's not a concern here. The lowlevel C floor function, that ma...
by phlip
Sun Jan 01, 2017 2:19 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9722
Views: 1501260

Re: Coding: Fleeting Thoughts

↶ [...] If floor(almost/just_about) returns 3.999999999999999999916 [...] Then that would be a bug. floor(x) is always going to be exactly an integer. For -2 1024 < x < 2 1024 (or thereabouts, I CBA to calculate the exact endpoints), every integer is exactly representable as a float, so you shouldn...
by phlip
Fri Dec 23, 2016 1:40 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9722
Views: 1501260

Re: Coding: Fleeting Thoughts

EvanED wrote:Not to mention:

Code: Select all

> typeof []
"object"


which I guess isn't definitive but is suggestive.

Yeah, but typeof most things in Javascript is "object", that doesn't really narrow it down much...
by phlip
Wed Dec 14, 2016 4:02 am UTC
Forum: Logic Puzzles
Topic: Infinite Balls and Jugs [solution]
Replies: 611
Views: 68835

Re: Infinite Balls and Jugs [solution]

Defining B n ={n+1,n+2,...10n} L sup = ∩ n≥1 ∪ j≥n B j Every ∪ j will contain all members of B ∞ , therefore the intersection of all ∪ j also contains all members of B ∞ L inf = ∪ n≥1 ∩ j≥n B j ∩ j=∞ B j = B ∞ , therefore the union of all ∩ j≥n B j = B ∞ So the limit of B is B ∞ and I can't see any...
by phlip
Mon Dec 12, 2016 10:41 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9722
Views: 1501260

Re: Coding: Fleeting Thoughts

Yeah, C's "struct tm" uses a 0-based month number but a 1-based day number. And originally it used a two-digit year, but now out of backwards compatibility it uses "year - 1900". So today is 13/11/116 according to C. It is garbage, and every language that does the same and justif...
by phlip
Sun Dec 11, 2016 9:05 pm UTC
Forum: Logic Puzzles
Topic: Infinite Balls and Jugs [solution]
Replies: 611
Views: 68835

Re: Infinite Balls and Jugs [solution]

(Typing this post on my phone, so forgive me not using as much fancy formatting as I normally use...) For lim_sup you need to evaluate L sup = ∩ n≥1 ∪ j≥n B j But ∪ j≥n B j = {n+1,n+2,...} So L sup = ∩ n≥1 {n+1,n+2,...} Which for any finite limit to n is clearly not {}, and in fact as n increases an...
by phlip
Fri Dec 09, 2016 5:19 am UTC
Forum: Logic Puzzles
Topic: Infinite Balls and Jugs [solution]
Replies: 611
Views: 68835

Re: Infinite Balls and Jugs [solution]

We have differing opinions on whether a fully instantiated infinite set of numbers includes infinite numbers or not. So whatever I answer here will only lead to us going round in circles. If you don't like thinking that N contains these infinite values when it's fully evaluated [...] OK then, let's...
by phlip
Wed Dec 07, 2016 1:18 pm UTC
Forum: Logic Puzzles
Topic: Infinite Balls and Jugs [solution]
Replies: 611
Views: 68835

Re: Infinite Balls and Jugs [solution]

↶ Take an infinite set S ={1,1,1,1,....} Append another 1. Or a hundred of them, or an infinite number. You have the same set. Do that backwards, you have partitioned S into an infinite set and another set. That is not an infinite set. That is a finite set. With one element. That element is 1. This...
by phlip
Wed Dec 07, 2016 9:17 am UTC
Forum: What If?
Topic: What-If 0019: "Tie Vote"
Replies: 57
Views: 14681

Re: What-If 0019: "Tie Vote"

↶ 2.9 × 10^-21 bales is not 29 zeptobales, it's 2.9. So either the text or the calculation result is wrong. :shock: :shock: :shock: According to Wolfram|Alpha it's the calculation result, the correct figure is 2.9×10 −20 bales/second. Probably a typo due to having the "zepto" prefix on th...
by phlip
Tue Dec 06, 2016 12:55 pm UTC
Forum: Logic Puzzles
Topic: Infinite Balls and Jugs [solution]
Replies: 611
Views: 68835

Re: Infinite Balls and Jugs [solution]

↶ It should be pretty clear that f∞ is 1 everywhere, while g∞ is 0 everywhere. Are you sure that g∞ is 0 everywhere? If g i is only defined for finite i then for very large i g has a very large number of 1's. If g is defined for infinite i then I'd argue that g∞ has an infinite number of 1's (for n...
by phlip
Sun Dec 04, 2016 2:30 am UTC
Forum: Logic Puzzles
Topic: Infinite Balls and Jugs [solution]
Replies: 611
Views: 68835

Re: Infinite Balls and Jugs [solution]

↶ I know I mentioned this, when we were talking about the append-0 game vs. the remove balls game. I said that since a_i and r_i (for append step i and remove step i) are the exact same function (not just have the same counts of 1's and 0's), they must have the same limit. It was argued that since ...
by phlip
Sat Dec 03, 2016 2:26 pm UTC
Forum: Logic Puzzles
Topic: Infinite Balls and Jugs [solution]
Replies: 611
Views: 68835

Re: Infinite Balls and Jugs [solution]

↶ If you want to model the game using sets of entities that have a mysterious knowledge of their past then you can do that too, but then they are no longer numbers and you can't treat them as such. I think it's worth reiterating that the limit we're looking at here is a pointwise limit. That is, to...
by phlip
Mon Nov 28, 2016 12:13 pm UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9722
Views: 1501260

Re: Coding: Fleeting Thoughts

Polish notation (either normal or reverse) isn't too hard to extend to add operators that take any fixed number of parameters... but adding functions that take a variable number of parameters is a whole other ballgame. Chances are, just doing "eat the whole stack" isn't actually what you w...
by phlip
Thu Nov 17, 2016 2:31 pm UTC
Forum: General
Topic: Blistering blue barnacles
Replies: 28276
Views: 2408942

Re: ANGRY NATTERINGS

)
by phlip
Thu Nov 10, 2016 11:22 am UTC
Forum: Logic Puzzles
Topic: Infinite Balls and Jugs [solution]
Replies: 611
Views: 68835

Re: Infinite Balls and Jugs [solution]

↶ It, and the infinite other balls were put in at the stroke of midnight. Why would you assume such a thing, when the puzzle pretty explicitly only describes us doing things strictly before midnight? At midnight, we're doing nothing except checking to see what's left in the jug. If you are prepared...
by phlip
Wed Nov 09, 2016 11:39 pm UTC
Forum: Logic Puzzles
Topic: Infinite Balls and Jugs [solution]
Replies: 611
Views: 68835

Re: Infinite Balls and Jugs [solution]

↶ They were put in during the infinite number of infinitesimally short steps that happened on the stroke of midnight. "During" a number of steps? Be specific. At what specific time was this ball: ↶ How many steps had been taken when midnight arrived? That number plus one will tell you the...
by phlip
Mon Nov 07, 2016 2:47 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9722
Views: 1501260

Re: Coding: Fleeting Thoughts

Code: Select all

' Some assertions to verify maths is still working
¼ = 0.25
½ = 0.5
¾ = 0.75
' OK, everything seems good

Sub t()
    x = 2
    If x * ½ = 1 Then MsgBox "Multiplication still works as expected"
End Sub
by phlip
Mon Nov 07, 2016 2:38 am UTC
Forum: Coding
Topic: Coding: Fleeting Thoughts
Replies: 9722
Views: 1501260

Re: Coding: Fleeting Thoughts

jeanrenaud wrote:
I'm just not sure why my post got here. I made a separate post for it...

Yeah, I merged it in... I thought it made a better fit in here (and would probably get more traction)
by phlip
Fri Nov 04, 2016 9:19 am UTC
Forum: Science
Topic: Some help me with Calculation of impact speed please
Replies: 4
Views: 1851

Re: Some help me with Calculation of impact speed please

If you're close enough to the surface that you can treat the acceleration as effectively constant, then you can just use the standard equations of motion ... specifically, the one you want is: v² − u² = 2as (Where s is your displacement, a is your acceleration, u is your initial velocity, v is your ...
by phlip
Wed Nov 02, 2016 1:00 pm UTC
Forum: News & Articles
Topic: In other news... (humorous news items)
Replies: 13863
Views: 1813011

Re: In other news... (humorous news items, etc)

↶ "What do you do for a living?" "I fokk horses" "Pardon?" "Yes, Paarden". Can someone explain this to me? Google Translate, the only way we true Americans can understand other languages, was useless. Google Translate was able to figure it out for me ...
by phlip
Sun Oct 30, 2016 10:49 pm UTC
Forum: General
Topic: ITT: We make xkcd slightly worse.
Replies: 8589
Views: 1341676

Re: ITT: We make xkcd slightly worse.

Monika wrote:
WHEN OTHERS.
WRITE: / 'None of the above'.

Nice.

Go to advanced search